I'm having trouble finding the differences between data synchronization and replication.

From what I can tell, replication is making all data between 2 databases the same. Synchronization doesn't necessarily make ALL DATA between the two databases the same. Replication is a one time transfer, where synchronization can be small updates to keep data consistent? I'm not too sure, please correct me here?

If I was to have a central mySQL database which stores multiple mobiles data, and my aim was to keep the data from the phone the same as the data from mySQL (only the certain users data), would that be synchronization or replication or both? It would initially get all the users data(replication), and then sent any updated data after that(synchronization)?

Hope can someone can clear up the confusion, many thanks!

有帮助吗?

解决方案

To put it very bluntly:

  • Replication implies strongly that there are two or more copies of (all) the data
  • Synchronization implies that two or more copies of data are being kept up-to-date, but not necessarily that each copy contains all of the data (although this is typically the case for database syncing)

But I'd wager the terms are often used interchangeably, I'm pretty sure I could find plenty of examples of "replication" being used to describe multiple databases being kept in sync.

So don't get too hung up on these two terms - they mean the same general thing, but obviously there can be a vast difference in how different database systems or tools achieve whatever they refer to as "replication" or "synchronization".

其他提示

As the previous poster explained, they are used interchangeably, however they are meant to have distinct meanings.

As he said, Replication is a situation where there are two or more "replicas" of a database in existence at the same time. This allows users to work on the "same" database without competing for access time or having to cope with technical constraints such as communication transit times or network delays.

Synchronization will follow after a certain predetermined period of time (could be minutes, hours, days, weeks) and amounts to the remerging of the changes made to the different replicas of the database into the master database.

1) Essentially replication is making multiples databases the same instantly with almost zero or near zero time lag.

2) Synchronization is same as above but time lag is => 0 in (seconds, min, days, months, etc).

3) The time delay is a major difference.

4) So, technically replication is a sub-set of synchronization. That is why you hear things like Replicated synchronization.

Some of the answer to this depends on the context in which it's used.

For example, the Informatica ETL tools have "Data Replication" and "Data Synchronization" tasks - here, data replication implies that the fields in the source tables are copied exactly to the corresponding fields in the target tables, whereas the synchronization allows for transformations - formulas, lookups, etc. Additionally, replication is a one-way flow, e.g. production database to backup. Synchronization may be bidirectional, e.g. a service may provide both a web interface to a central server, and an app which caries a local copy for offline use - updates could come in through either db and be synchronized to the other.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top