Multimaster Replication Routing for Conflict-Aware Data Consistency
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Distributed databases face challenges in maintaining consistency and handling conflicts, particularly in geographically dispersed systems, leading to trade-offs in availability, consistency, and partition tolerance, resulting in data inconsistency and loss.
Innovation Solution
A N-way Multimaster database replication framework that utilizes geographical proximity mean value (GPMV) and sender internet protocol (IP) affinity value (SIPAV) to route transactions, generate unique primary keys, and monitor conflicts, ensuring seamless data replication across multiple servers.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If data is replicated asynchronously among different geographical regions to meet availability demands, then system availability is improved, but data consistency deteriorates
Solution Approach 1:
The system generates unique primary keys in advance using a distributed sequence generator that incorporates geographical proximity mean value (GPMV) and sender IP affinity value (SIPAV). This preliminary key generation prevents conflicts before they occur during asynchronous replication, allowing each node to independently identify and resolve updates without waiting for consistency checks from other nodes.
Solution Approach 2:
The patent introduces a conflict resolution mechanism that acts as an intermediary between replicated data nodes. When conflicts are detected during replication, the system uses foreign key constraint validation and parent-child association monitoring to mediate between competing updates, selecting the most recent valid update based on timestamp and geographical affinity metrics rather than simple last-writer-wins arbitration.
2Loss of information
If traditional conflict resolution mechanisms are used in replication, then data consistency is improved, but data loss occurs
Solution Approach 1:
The system implements continuous feedback monitoring through dynamic conflict detection that validates foreign key constraints and parent-child associations in real-time during replication. When conflicts are detected, the system provides feedback to the replication pipeline to adjust the replication strategy, ensuring no valid updates are lost while maintaining consistency. The feedback loop continuously monitors replication status and adjusts conflict resolution decisions based on current system state.
Solution Approach 2:
The conflict resolution mechanism is dynamic rather than static, adapting its behavior based on the specific conflict scenario detected. The system dynamically evaluates foreign key constraints, parent-child relationships, and geographical affinity metrics to determine the appropriate resolution action for each conflict case, rather than applying a fixed last-writer-wins rule that causes data loss.
3Productivity
If geographically dispersed database nodes are used to reduce latency, then system performance is improved, but conflict monitoring complexity increases
Solution Approach 1:
Each database node is configured with local geographical affinity information and sender IP metadata, allowing conflict resolution decisions to be made locally based on local conditions rather than requiring centralized coordination. The GPMV and SIPAV calculations are performed locally at each node using locally available information, reducing the complexity of inter-node communication while maintaining effective conflict monitoring across the distributed system.
Data Source
AI summary
In distributed data management traditional databases often struggle to maintain consistency and handle conflicts. Traditional solutions prioritize specific combinations of properties, resulting in trade-offs that impact user experience and application functionality. Present disclosure provides systems and methods that route incoming transaction associated with application to corresponding database server (DBS) by integrating geographical proximity mean value, and sender internet protocol affinity value. The incoming transaction is processed to extract data manipulation language (DML) operation written by the application and replicated to each DBS other than a DBS on which the application is directly applying a data through the incoming transactions. A primary key is generated by allocating an unique identifier if the DML operation is inserted on identified DBS. The primary key of record is updated from the incoming transaction. A conflict associated with parent and child association of the DML operation is dynamically monitored based on integrity Foreign key Constraint.


