I am seeing a big number of "pending writes" for my Heroku Connect instance. How is this calculated? How can I check if all is working as expected? Can I do something to speed up the process if I don't need some of these changes to be processed?
When working with read-write mappings, Heroku Connect will capture any changes to the data in their corresponding table in the database, and it will create new records in the
_trigger_log table to process those changes and sync them to Salesforce.
"Pending writes", as reported by Heroku Connect, is the sum of all the records in the
_trigger_log table that are in the
BULKSENT state. Check this article of the DevCenter to learn more about what the different states are.
If you're seeing a high number of pending writes for your connection, but you know that you don't need some of these to be synced (for example, if you know if the changes will be
IGNORED by Heroku Connect), you could try to manually edit the state of those records in the
_trigger_log table and set them to
IGNORED (note the difference between the
IGNORE - to be ignored, but still needs to be processed by Connect, vs.
IGNORED - already processed by Connect). Manually editing the
_trigger_log table is not recommended as it could cause data to not get synced to Salesforce, but this might help speed up the sync process.