Database Page Descriptor Snapshot Sharing for Read-Only Transactions
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Database systems face performance issues due to transaction contention, particularly in handling concurrent transactions, which leads to sub-optimal performance.
Innovation Solution
A method and system are introduced to share snapshots between read-only transactions by using page descriptors to track modifications from read-write transactions and maintain references to existing read-only snapshots, allowing read-only transactions to access or create snapshots for sharing purposes.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Productivity
If traditional transaction handling methods are used in database systems, then each transaction can be processed independently, but transaction contention occurs and performance deteriorates under concurrent workloads
Solution Approach 1:
The patent segments the database system into multiple independent transaction processing threads that can operate concurrently without blocking each other. Each thread maintains its own transaction context and accesses shared data through snapshot isolation, allowing parallel execution while preserving transactional correctness.
Solution Approach 2:
The system performs preliminary actions by creating and storing snapshots of data pages before transactions begin. These snapshots are pre-prepared and stored in memory, allowing read-only transactions to immediately access consistent data states without blocking or waiting for other transactions to complete.
2Productivity
If snapshots are reconstructed for each read-only transaction, then transaction isolation is maintained, but duplicate snapshot reconstruction occurs and processing efficiency decreases
Solution Approach 1:
The patent merges multiple read-only transactions by having them share common snapshots when possible. The system checks whether existing snapshots can satisfy multiple transactions' requirements and redirects them to use the same snapshot, eliminating redundant reconstruction operations and improving overall processing efficiency.
Solution Approach 2:
Instead of reconstructing snapshots for every read-only transaction, the system creates copies of existing snapshots and assigns them to transactions that need consistent data views. This copying approach is much more efficient than full reconstruction while maintaining the required isolation properties.
3Reliability
If log records are undone for every read-only transaction, then transaction rollback capability is maintained, but unnecessary undo operations occur and system performance degrades
Solution Approach 1:
The patent applies partial action by selectively performing log record undo operations only when absolutely necessary. The system determines whether a read-only transaction actually requires rollback based on snapshot validity and transaction outcomes, avoiding unnecessary undo operations that would degrade performance while maintaining rollback capability when needed.
Data Source
AI summary
In general, embodiments of the technology relate to a method for processing read-only transactions. The method includes receiving a read-only transaction, wherein the read-only transaction specifies a page, obtaining a page descriptor, from a page cache, for the page, where the page descriptor comprises a plurality of entries, identifying an entry of the plurality of entries in the page descriptor for the read-only transaction, and processing the read-only transaction using a snapshot of the page associated with the entry.


