This synchronization process is defined in the pipeline batch xDB Contacts to CRM Sync Pipeline Batch.
The contact synchronization process involves the following steps:
- Read contacts from xDB.
- Loop through the contacts from xDB. For each contact:
- Get the CRM contact that corresponds to the xDB contact if one exists, otherwise create a new CRM contact.
- Apply value mappings by reading values from the xDB contact and writing those values to the CRM contact.
- Save the CRM contact.
- If the CRM contact was created.
- Get the xDB contact.
- Get the contact from the work queue that corresponds to the xDB contact if one exists, otherwise add the contact to the work queue.
- Apply value mappings by reading values the CRM contact and writing those values to the work queue contact.
Writing data back to the xDB contact is needed so that the CRM contact id is set on the xDB contact. This facilitates future synchronization.
- Read contacts from work queue.
- Create a known contact set for the xDB bulk contact update API.
- Loop through the contacts from the work queue. For each contact:
- Add the contact to the known contact set.
- Submit the known contact set.
A more detailed sequence diagram is available