Blendr.io knowledge base

Two-way data synchronization

Design patterns for two-way data synchronization

Two-way sync is between two platforms (A and B) where data can be changed in either platform.

All remarks for one-way sync also apply to two-way syncs! On top of that, two-way sync requires the below points of attention.

Example two-way sync pattern

Here's a simple example of 2-way sync of Contacts, without deletes:

Endless loops

Avoid endless loops where an update from A to B causes an update from B to A, which causes a new update from A to B etc. This is accomplished by using the "only update when needed" rule (see above) so that timestamps of objects are not increased when no changes are needed.

Conflict handling

Keep the synchronization intervals as low as possible to reduce the change of conflicts (change made to the same object in A and in B at the same time).

Comparison Blends

A good practice is to create a "Compare" Blend that compares all data from A and B, to make sure that the synchronization is working as expected. A compare blend could run e.g. once a day or even once a week because it typically needs to process a high amount of data.

A Compare blend could reveal issues that otherwise go unnoticed, e.g. issues related to a human mistake in the Blend, issues related to timestamps, issues related to the API or Webhooks of one of the platforms, etc.

You can send out an email alert in the Compare Blend when issues are detected.

Example:

Updated 8 months ago

Two-way data synchronization


Design patterns for two-way data synchronization

Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.