Key-Value Store Cursor Search for Tombstone-Heavy Key Sequences
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing database cursor operations in key-value stores are hindered by high latency due to the need to iterate through numerous consecutive tombstone keys during setup, particularly in sequences with a large number of deletions, leading to performance bottlenecks and reduced throughput in range delete operations.
Innovation Solution
A key sequence searching technique that initializes memory and media keys greater than or equal to the specified key, performing a merging operation to efficiently compare and select the smallest valid key, thereby reducing the need to advance through entire sequences of tombstones.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Measurement precision
If database cursor operations iterate through consecutive tombstone keys during setup, then the cursor can locate valid keys in key-value stores, but the operation latency increases significantly
Solution Approach 1:
The patent segments the key sequence into two separate sequences: memory keys and media keys. This segmentation allows the system to search both sequences simultaneously rather than iterating through all keys sequentially, thereby reducing cursor setup latency while maintaining accurate key location capability.
Solution Approach 2:
The patent performs preliminary actions by pre-positioning the cursor at the first key in the memory sequence that is greater than or equal to the specified key, and simultaneously at the first key in the media sequence that meets the same criterion. This preliminary positioning eliminates the need to iterate through tombstone keys during cursor setup, reducing latency while ensuring accurate key location.
2Reliability
If the cursor advances through entire sequences of tombstones, then all tombstone keys are examined, but the operation throughput decreases
Solution Approach 1:
The patent merges the search operations on memory keys and media keys into a single coordinated process. By simultaneously searching both sequences and comparing results, the system verifies tombstone keys reliably without advancing through entire sequences, thereby maintaining verification completeness while improving range delete throughput.
Solution Approach 2:
The patent implements skipping by directly positioning the cursor at relevant keys in both memory and media sequences without advancing through intermediate tombstone keys. This skipping mechanism maintains reliability by still examining necessary tombstone keys through coordinated search, while significantly improving productivity by avoiding unnecessary sequential advancement.
3Ease of operation
If the system performs sequential cursor setup operations, then each key can be processed in order, but unnecessary cursor requests are generated
Solution Approach 1:
The patent performs preliminary positioning of the cursor at the appropriate key in both memory and media sequences before any processing occurs. This preliminary action ensures that subsequent key processing maintains sequentiality while avoiding unnecessary cursor requests, as the cursor is already positioned correctly from the start.
Solution Approach 2:
The patent implements dynamic cursor positioning by simultaneously adjusting the cursor position in both memory and media sequences based on the specified key. This dynamic approach maintains the ease of sequential key processing while reducing device complexity by minimizing the number of cursor requests needed to achieve the same result.
Data Source
AI summary
A system includes a memory device a processing device, operatively coupled to the memory device. The processing device is configured to receive a request to identify a target key in a key-value store based on a specified key; identify, in at least one of a plurality of sequences of memory keys, the target key based on the specified key, where the plurality of sequences of memory keys includes a sequence of memory keys and a sequence of media keys that comprises designated media keys, where each of the designated media keys is designated as being deleted, where the identifying comprises comparing each of the designated media keys to the specified key; and perform a database operation using the target key.


