Should I provide user with a manual data sync button?
After reading the Gadget documentation, I learned there are various ways to trigger data synchronization. What conditions are typically set for this? For instance, when a product is updated or deleted or when a new product is created?
Alternatively, should I provide a sync button that allows user to manually synchronize every 10 minutes?
1 Reply
Hello,
You should not run syncs when there's a webhook or a model action is run. That can cause you to have a lot more syncs running (and more request time accrued) than necessary/wanted
I would also not recommend giving users the ability to run syncs on their own as they might abuse it.
Syncs should be used in a way to populate the database or retrieve missing data. Webhooks and our nightly sync will handle populating your database otherwise