主权项 |
1. One or more computer-storage media storing computer-executable instructions that, when executed by a computing device having a processor, cause the computing device to perform a method of replicating data in distributed storage, the method comprising:
retrieving a replication message from a message queue associated with a source table, the source table being one of a plurality of source tables in a replication group, the replication message comprising a row identifier; identifying one or more target storages within the replication group, the target storages including tables within the replication group; obtaining a table row corresponding to the row identifier and a first entity tag (eTag) for the table row from each of the one or more target storages, an eTag comprises an identifier for a specific version of the table row; determining a winning row from the obtained rows based on a latest client timestamp of the obtained rows, the winning row being a table row with a latest version of the table row; creating replication operations based on the winning row, wherein a replication operation comprises instructions on inserting data from the winning row in to one or more target storages; and performing batch execution of the replication operations to the one or more target storages. |