The core data synchronisation process works via the creation and population of database tables during the installation process, and these are then updated and maintained using a handful of observers and cron services.
Before you start
Things you need to know:
The most accurate and up-to-date list of our cron tasks and their timings is our main crontab.xml file.
Creation of databases
Upon installation of the connector, we create nine new database tables. These are:
All contacts who will be synced to Dotdigital
All orders that will be synced
All wishlists that will be synced
All reviews that will be synced
All products that will be synced
All contacts due to be enrolled or that have been enrolled into a program that will be synced
All campaign sends sent or due to be sent (abandoned cart or review requests only) that will be synced
All batches of data that have been imported or due to be imported that will be synced
Stores quotes for the abandoned cart email series
Stores consent data if Stores > Configuration > Dotdigital > Configuration > Consent settings are enabled
Stores coupon properties for coupons created via our coupon URL
Logs authorization failures when our dynamic content URLs are accessed with an incorrect passcode
Stores exclusion rules configured in Marketing > Exclusion Rules
During installation these tables become populated with your historical data, after which time they are updated automatically by cron services.
The following cron services batch data from these tables and add them to the email_importer table ready for import:
These three jobs batch data from the email_contact table. Runs every 15 minutes by default.
Batches data from the email_order table. Runs every 15 minutes by default.
Batches data from email_review and email_wishlist tables. Runs every 15 minutes by default.
Batches product data from the email_catalog table. Runs every 15 minutes by default.
All of the above cron services can have their frequency configured.
All of this data gets batched and then added to the email_importer table, which involves the running of the following cron service:
Looks for the oldest non-imported import and kicks off an import. This runs every 5 minutes (again, the frequency can be configured), checks the status of the last import and, if complete, marks it as done and then starts the next one.
The importer also checks the import fault file for all contact imports and if it contains suppressed contacts, it updates their status in both the email_contact table and the core Adobe Commerce newsletter table.
The following cron services also perform the following tasks:
Detects abandoned carts based on the time settings you specify and adds contacts that are due to receive an email to email_campaign table (this runs every 5 minutes)
Creates contacts and performs sends of all unsent campaigns (abandoned cart and review requests only; this runs every 5 minutes)
Creates and enrols any contacts into the email_automation table that haven't been added yet (this runs every 15 minutes)
Archives files created from the batching process (this runs once a month, so it keeps your table clean. Contact support if this isn't working)
Scans your tables for errors, to be flagged in System Alerts (runs every 15 minutes)
Sends data about your Adobe Commerce installation and your connector configuration to Dotdigital (runs once a week)
Fetches recent suppressions from Dotdigital and unsubscribes matching email addresses in Adobe Commerce
Fetches recently-modified contacts in Dotdigital and resubscribes matching email addresses in Adobe Commerce