You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@asterixdb.apache.org by "Bhukailas Reddy (JIRA)" <ji...@apache.org> on 2019/08/09 09:30:00 UTC
[jira] [Created] (ASTERIXDB-2628) if-modified-since http header to
avoid data inconsistencies in DB. Optimistic locking
Bhukailas Reddy created ASTERIXDB-2628:
------------------------------------------
Summary: if-modified-since http header to avoid data inconsistencies in DB. Optimistic locking
Key: ASTERIXDB-2628
URL: https://issues.apache.org/jira/browse/ASTERIXDB-2628
Project: Apache AsterixDB
Issue Type: New Feature
Components: API - HTTP API
Reporter: Bhukailas Reddy
Asterix does not let users know if the updates requests are coming with old data.
eg:-
1) User 1 inserts a record
2) User 2 fetches the record created by User 1
3) User 1 updates the record
4) User 2 updates the same record without knowing that the record was updated by User 1 mean while.
In this scenario, table will have a timestamp column. each time when user create/updates a record... the timestamp column gets updated.
If some one requires optimistic locking the user can comeback with Http request with header
*if-modified-since* with column name and last updated time.
If the user is coming back with timestamp older than current timestamp in table... send error response with some appropriate code
--
This message was sent by Atlassian JIRA
(v7.6.14#76016)