Patent ID: 8527459

Claim:
A system for replicating data among heterogeneous databases, comprising: an initializing module for creating and initializing at least one shared memory, at least one message queue and at least one semaphore in a computer for data storage; a source data processing module including a data reader for reading source data from at least one source database, a data adapter for converting the source data read by the data reader into target data to be stored in at least one target database, and a data loader for loading the converted target data into the shared memory; a target data replication module for replicating the target data stored in the shared memory to the at least one target database according to the messages in the at least one message queue; and a cleaning module for releasing the shared memory after the data stored therein has already been copied, wherein each of the at least one shared memory corresponds to a target table in a target database, and is configured to include: a shared memory body including a plurality of shared memory segments for storing the data, wherein a basic storage unit in each shared memory segment is data element corresponding to a record or a combination of a part of fields of the record in the target table of the target database; and a shared memory header for storing the management information for the shared memory body, wherein the management information includes the quantity of the shared memory segments in the shared memory body, the quantity of the data elements in each shared memory segment, the length of the record of the target data, and the running status of each shared memory segment, wherein each of the at least one message queue comprises a task message queue for storing task messages, and an idle memory notification message queue for storing the message which notifies an occurrence of the idle shared memory segment.