Auto-conflict detection and resolution in Maria DB

Do we have a way to automate the conflict handling while having asynchronous replication between 2 Maria DB servers. For e.g., if a user has updated the same record at the 2 DB servers with different values, then do we have a way to insert our logic in this situation which should be used to decide which record should be considered as the final record out of these 2.

Also can we add some logic here so that we can set the final value of the record which is calculated by using both of the inserted values? For e.g., suppose we are storing the data regarding the customer current balance. Now at one site we have executed the transaction regarding the money withdrawal while at the other site we have executed a deposit related transaction. Thus when the data would be finally consolidated across the 2 sites, the current record should contain the resultant value of these 2 transactions.

Leave a Comment