Our system need data sync with each sub system, because data transfer is bidirectional, so can't use mysql master and slave, at present I use two way to solve this problem.
With other system, I use hibernate interceptor to intercept the changed data, and write a log to record which table which data at which time changed, and when time arrive, I searche the latest data, then generate an xml document and transfer this document to other system. XML maybe like this
<?xml version="1.0" encoding="UTF-8"?>
<datasync name="employee" site="A">
<syncdata name="id">12345</syncdata >
<syncdata name="employee name">*******</syncdata >
</datasync>
<datasync name="employee" site="B">
<syncdata name="id">2345</syncdata >
<syncdata name="email">*******</syncdata >
</datasync>
I use mysql master idea, not use slave idea as the way between our parent system an sub system data sync.
At every night, Out service call a bat file to execute some command and generate the update sql from mysqlbinlog, then according this sql, we can know which data changed, according requirement to analysis the update sql, and update data to each sub system and parent system.
分享到:
相关推荐
Apache Hadoop YARN is the modern distributed operating system for big data applications. It morphed the Hadoop compute layer to be a common resource-management platform that can host a wide variety of...
Please refer to the help documentation for more details about sync configuration. Files ----- mlo.exe - MyLifeOrganized application mlo.chm - Help documentation MLOWMSync.exe - MLO Windows ...
How to write on-device applications that store all their data locally (some will then sync to a server-side store when later connected) How to write games as well as useful apps Who is this book for?
See any operating system documentation about shared libraries for more information, such as the ld(1) and ld.so(8) manual pages. ---------------------------------------------------------------------- ...
Sync local directories with remote (FTP/SFTP) directories Compare Modified File Against Source File How to compare the modified file against the source file on disk. Column Based Find and Replace Need...
An application that demonstrates how to query the system contacts provider using the ContactsContract API, as well as insert contacts into a specific account. Home A home screen replacement ...
- **Displaying Enclosure or Device Specific Data (display):** Display detailed information about a specific enclosure or device: ```sh luxadm display /dev/rdsk/cXtYdZl0 ``` - **Displaying Disk ...
3DVia Composer - convenient and functional system design multimedia content, automating the process of creating instructions for assembly / disassembly, technical illustrations, interactive 3D ...
ipc_wmcopy.zip Demonstrates the use of WM_COPYDATA(94KB)<END><br>52,StartProcessesInOrder_src.zip This utility uses very little system resources to launch apps base on a timer.(18KB)<END><br>53,...
It contains information about where to fetch the source, what patches to apply and how, and how the package should be installed on the system. This allows automated tools to fetch, build and install ...
Changes in 2.4.6 (February 22, 2011): Brief summary : - Support more host OS to run on: - Include win64 native binary in the release. - Fixed failures on big endian hosts. - BIOS: Support for up to...
Chapter 4—Basic constructs and elementary data types.......................................................49 4.1. Filenames—Keywords—Identifiers......................................................
Chapter 4—Basic constructs and elementary data types.......................................................49 4.1. Filenames—Keywords—Identifiers......................................................