On-Demand Database Data Locking via Version Identifiers
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Conventional database systems face limitations in locking data during remote editing, leading to unacceptable delays in data updates, particularly when edits are made over extended periods, which can result in race conditions and compromised data integrity.
Innovation Solution
Implementing mechanisms and methods for locking data in an on-demand database service that allow data to be locked only when edits are saved, ensuring that edits are applied without allowing other users to modify the data simultaneously, using version identifiers to conditionally apply changes and prevent deadlocks.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If data is locked for extended periods during remote editing, then data integrity is improved, but user productivity deteriorates due to unacceptable delays in data updates
Solution Approach 1:
The patent implements dynamic locking that adapts the locking duration based on the editing context. Instead of fixed extended locking, the system applies locking only for the specific time window when save operations occur, automatically releasing locks when not needed. This dynamic approach maintains data integrity during critical save operations while allowing continuous access during browsing and editing phases.
Solution Approach 2:
The system employs periodic locking synchronized with user save actions rather than continuous locking. The lock is applied periodically at save points and released between saves, creating a rhythm of lock-acquire-database-write-lock-release cycles. This periodic action ensures integrity only when necessary while maximizing productivity during intermediate periods.
2Reliability
If data is locked during editing operations, then race conditions are prevented, but data accessibility deteriorates for other authorized users
Solution Approach 1:
The patent implements fine-grained locking at the record level rather than table-level or database-level locking. When a user saves edits to specific data records, locks are applied only to those particular records being modified. Other records remain unlocked and accessible to other users, providing local quality control that prevents race conditions on modified data while maintaining accessibility to unchanged data.
Solution Approach 2:
The system segments the database into individually lockable records or rows. Instead of locking entire tables or databases during editing, the patent divides the data structure into discrete segments (records) that can be locked independently. This segmentation allows multiple users to work on different records simultaneously while preventing concurrent modifications to the same record, thus preventing race conditions without blocking overall system accessibility.
3Reliability
If data locking is implemented for remote web page edits, then concurrent modifications are prevented, but update timing deteriorates causing lengthy delays
Solution Approach 1:
The patent implements preliminary locking immediately when a user initiates a save operation, before the actual database write occurs. The lock is acquired in advance during the save command processing phase, ensuring that no other user can modify the data during the critical write window. This preliminary action prevents race conditions while minimizing the total time the lock is held, as the lock is released immediately after the write completes.
Data Source
AI summary
In accordance with embodiments, there are provided mechanisms and methods for locking data in an on-demand database service. These mechanisms and methods for locking data in an on-demand database service can enable embodiments to prevent race conditions, etc. The ability of embodiments to provide such feature may lead to enhanced data integrity when editing data.


