Two-way synchronization

The synchronization provided with Connect is designed to work in both directions. However, the most common scenario is to synchronize only one way, from the external commerce system (ECS) to Sitecore content.

The logic that determines whether an entity is updated in the ECS, the content management system (CMS), or both, is based on a Direction parameter and the configured strategy. Each synchronization method takes an optional Direction parameter. If not provided, the default direction value is Direction.Inbound, which means the product data is taken from the ECS and imported into the CMS. The possible direction values are:

  • Direction.Inbound  - one-way synchronization from the ECS to the CMS. This is the default value.

  • Direction.Outbound  - one-way synchronization from the CMS to the ECS.

  • Direction.Both  - two-way synchronization based on the configured synchronization strategy.

The default synchronization strategy is based on time stamps for when the entity was last updated and the last one (newest date and time) wins, meaning if the entity was last updated in the external system, then it gets overwritten in Sitecore and vice versa. Only when specifying two-way synchronize with Direction.Both will the synchronization strategy be evaluated to determine which way data flows. The strategy is executed per product and all its constituent entities.