A data synchronization method and device

A data synchronization and database technology, applied in the database field, can solve the problems of error node data not changing, difficult to receive, inconsistent data of each node, etc., to achieve the effect of maintaining data consistency

Inactive Publication Date: 2019-01-08
ZHENGZHOU YUNHAI INFORMATION TECH CO LTD
View PDF4 Cites 2 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

If you frequently add, delete, or modify the global table, due to Mycat's weak XA transaction mechanism, frequent operations on the global table may cause abnormal situations: when a user modifies the global table and submits it, suddenly a node fails , it may happen that some nodes have been successfully modified but the data of the error node has not changed, making

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • A data synchronization method and device
  • A data synchronization method and device
  • A data synchronization method and device

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0042] In order to make the object, technical solution and advantages of the present invention clearer, the embodiments of the present invention will be further described in detail below in conjunction with specific embodiments and with reference to the accompanying drawings.

[0043] It should be noted that all expressions using "first" and "second" in the embodiments of the present invention are to distinguish two entities with the same name but different parameters or parameters that are not the same, see "first" and "second" It is only for the convenience of expression, and should not be construed as a limitation on the embodiments of the present invention, which will not be described one by one in the subsequent embodiments.

[0044] Based on the above purpose, the first aspect of the embodiments of the present invention proposes an embodiment of a data synchronization method for different database nodes or different types of database nodes. figure 2 What is shown is a s...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a data synchronization method and device. The method comprises the following steps: configuring a database middleware and enabling a table broadcasting mechanism of the database middleware; enabling the database middleware to receive the database statement of the data manipulation language; judging whether the database statement needs to execute the global table logic according to the configuration; when the database statement needs to execute the global table logic, using the table broadcast mechanism to broadcast the database statement table to all the database nodes;when the database statement does not need to execute global table logic, sending the database statement to all database nodes and executing the database statement. The data synchronization method andthe device provided by the invention can synchronize data for different database nodes or different types of database nodes, and maintain the data consistency of the global tables in the database.

Description

technical field [0001] The present invention relates to the field of databases, more specifically, to a data synchronization method and device. Background technique [0002] Mycat is an open source distributed database system and a database middleware that implements the MySQL protocol. Front-end users can regard it as a database agent and access it with MySQL client tools and command lines; the back-end can use MySQL's native (Native) protocol to communicate with multiple MySQL servers, and can also use JDBC protocol to communicate with most mainstream database servers communication. [0003] Transactions in Mycat mainly include SQL non-cross-shard transactions and SQL cross-shard transactions. For SQL transactions that do not cross shards, the SQL statement is only executed on one data node. At this time, the Mycat transaction mode is completely consistent with the standard database transaction mode. Whether commit and rollback can ensure strong consistency. For SQL cro...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
IPC IPC(8): G06F16/27G06F9/54
CPCG06F9/542
Inventor 王文庆杜彦魁
Owner ZHENGZHOU YUNHAI INFORMATION TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products