Trie-Based MVCC Database Indexing
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Current database systems face inefficiencies in multi-version concurrency control (MVCC) due to challenges in version storage, garbage collection, and index management, particularly in maintaining multiple versions of database objects and reclaiming obsolete space while ensuring performance and scalability.
Innovation Solution
The implementation of a trie data structure with a root node corresponding to specific versions, allowing for efficient storage location determination and memory management by using logical pointers and a copy-on-write approach, which integrates version storage, garbage collection, and index management into a single snapshot-consistent physical trie.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Adaptability or versatility
If multiple versions of database objects are maintained using traditional version storage schemes (append-only, time-travel, or delta-storage), then version storage capability is improved, but storage space overhead and access time increase due to maintaining version chains and traversing them to find appropriate versions
Solution Approach 1:
The patent segments the version storage structure into a hierarchical trie data structure where versions are organized by path components rather than linear chains. Each node in the trie represents a versioned object at a specific path, allowing direct navigation to any version without traversing a chain, thus reducing access time while maintaining version storage capability
Solution Approach 2:
The patent transitions from one-dimensional version chains (linear sequences of versions) to a multi-dimensional trie structure where versions are accessed through path-based navigation. This dimensional change allows simultaneous access to multiple versions through different paths without requiring chain traversal, improving access efficiency
2Adaptability or versatility
If version chains are maintained for each database object to support MVCC, then version storage is enabled, but device complexity increases due to the need to maintain and manage these chains
Solution Approach 1:
The patent merges the version storage structure with the index structure into a unified trie data structure. Instead of maintaining separate version chains and separate indexes, the trie serves both purposes by organizing data nodes and version information in a single hierarchical structure, thereby reducing overall system complexity
Solution Approach 2:
The trie data structure is designed to serve multiple functions simultaneously: it acts as both the index structure for locating database objects and the version storage mechanism for maintaining historical versions. This multi-functionality eliminates the need for separate structures, reducing complexity while maintaining MVCC capabilities
3Reliability
If indexes are updated after each version update to maintain consistency, then index accuracy is improved, but productivity decreases due to frequent index update operations
Solution Approach 1:
The patent performs index updates preliminarily by maintaining the trie structure in a consistent state before transactions commit. Version information is organized and made available in the trie ahead of time, allowing transactions to access consistent versions without requiring post-update index synchronization, thus improving throughput while maintaining consistency
4Quantity of substance
If garbage collection is performed frequently to reclaim obsolete version space, then storage efficiency is improved, but productivity decreases due to the overhead of scanning and removing obsolete versions
Solution Approach 1:
The patent implements self-service garbage collection where the trie structure automatically identifies and reclaims obsolete version space through its hierarchical organization. The structure inherently tracks which versions are still referenced by active transactions, allowing automatic reclamation without requiring external garbage collection processes, thus maintaining storage efficiency while preserving throughput
Data Source
AI summary
The invention describes a method for determining a storage location of a database object of a specific version, wherein indexes for each version of the database object are stored in a trie having a root node corresponding to the specific version, the method comprising: determining a trie corresponding to the specific version by accessing the root node of the trie corresponding to the specific version; determining an object identifier of the database object by traversing the trie corresponding to the specific version using a secondary key related to the database object as search key; determining the storage location of the database object by traversing the trie corresponding to the specific version using the determined object identifier as search key.


