Database Redo Log Replay for Consistent Secondary Systems
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
In database systems, maintaining data consistency between primary and secondary database systems during load balancing and high availability operations is challenging, as existing solutions often lead to divergent states between the two systems, causing inconsistent responses and requiring additional processing resources.
Innovation Solution
The proposed solution involves receiving log transaction information from the primary database system, parsing it to identify modified data objects, and replaying these transactions on both the main memory and persistence data volumes of the secondary database system, ensuring that both systems remain synchronized, with a common framework facilitating simultaneous updates and load balancing operations.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If a complete copy of the database is stored at both primary and secondary database systems to ensure data consistency and availability, then system reliability is improved, but device complexity and resource requirements increase
Solution Approach 1:
Instead of maintaining complete copies of the entire database at both primary and secondary systems, the patent applies copying by replicating only the changed data blocks through redo log records. The secondary system receives and applies these incremental copies of modified data, reducing the data replication burden while maintaining consistency and availability.
Solution Approach 2:
The patent extracts only the essential change information from the complete database operations and transfers it to the secondary system through redo logs. This extraction of change data rather than full data copies allows the secondary system to remain lightweight while still providing reliable backup and failover capabilities.
2Reliability
If the secondary database system performs all the same tasks as the primary system to maintain synchronization, then data consistency is improved, but productivity and processing efficiency decrease
Solution Approach 1:
The patent extracts only the change operations from the primary system's complete task set and transmits them as redo log records to the secondary system. This allows the secondary system to synchronize data consistency without executing all the same tasks, significantly improving processing efficiency while maintaining data integrity.
Solution Approach 2:
The patent segments the database operations into complete transactions at the primary system and incremental change records at the secondary system. By dividing the workload this way, the secondary system only processes necessary changes rather than replicating the entire operational workload, improving overall productivity.
3Reliability
If redo log records are replayed on both main memory and persistence data volumes to ensure consistency, then data integrity is improved, but loss of time and processing duration increase
Solution Approach 1:
The patent applies preliminary action by loading changed data blocks into the secondary system's main memory before persistence. This allows the secondary system to quickly process and respond to queries using in-memory data while maintaining the option to persist these changes to disk volumes, reducing the time required for data integrity verification and replay operations.
Data Source
AI summary
A computer implemented method for manipulating data comprises receiving log transaction information from a primary database system at a secondary database system and parsing the log transaction information to identify data objects that have been modified on the primary database system. The secondary database system determines whether the data objects are present in main memory on the secondary database system and whether the log transaction corresponds to a data manipulation language (DML) query or a data definition language (DDL) query. If the data objects are not in the main memory and the query is a DML query, they are copied from persistence data volumes to the main memory. The data objects in main memory are modified by replaying the log transactions on the data objects in the main memory. Then, the data objects in the persistence data volumes are modified. Related apparatus, systems, techniques and articles are also described.


