Skip to main content

Solution to automate sync with Hybris

Overview

Summary of our chosen proposed solution, from those detailed in the API spike documentation. We have chosen to move forward with Cloudinary notifications rather than the Search API, since it allows us to make real-time updates to our assets in Hybris, preventing it from becoming out of sync with Cloudinary. Any actions that are taken in Cloudinary will (almost) instantly be reflected in Hybris, without the need for a full re-sync or the need to wait for a specified time interval to pass. Notifications also have a much smaller payload, and prevent us from requesting and transforming more data than is needed as we would have with the Search API.

Status

Accepted

Context

We are changing our DAM platform from Amplience to Cloudinary. As part of this change, we also need to update the way that we sync our assets between our DAM (Cloudinary) and Hybris. Currently, we use manifest files from Amplience to instruct Hybris about which assets have been updated. A Hybris cronjob then fetches XML from Amplience, which it ingests and transforms before applying to products. We want to move to a more modern and efficient way of syncing with Hybris. After completing a spike into the APIs and options available from Cloudinary we completed 2 Proof of Concepts, one using the Cloudinary Search API and one using Cloudinary Notifications.

Now that we have completed the POC, through this process and our findings we have chosen to move forward with Cloudinary notifications.

Decision

We will use Cloudinary Notifications to send real-time updates to Hybris. This solution allows for a simpler, more modern architecture and the Notifications payload is smaller than that from the Search API. This solution is fully async, and we don't need to wait for a specified time interval before syncing the most up to date assets with Hybris.

Cloudinary - Hybris asset sync design - async

Consequences

Some consequences of this decision that are worth noting. Some are benefits and some are challenges that we will need to overcome:

  • Web teams will no longer have to wait long periods of time for updates to appear in Hybris
  • We will not need to determine a suitable time interval at which to fetch data from Cloudinary, updates will be in real time
  • We need to normalise event data from Notifications, since different events don't all have the same data structure but we want to ensure the data sent to Hybris is consistent.
  • There is the potential issue that it is harder for Hybris to consume real time data, and there could be challenges involved with multiple notifications for a single product e.g. if there were successive uploads, metadata changes etc
  • We need to determine the workflow of the web team - will they rely on metadata for approvals process? Will we only sync approved assets with Hybris?
  • We need to discuss and agree on the folder and sub folder structure with the web team, to ensure that we can easily identify whether an image is a gallery or mannequin image, what the product SKU is etc

Resources