3 ms·
> If you need strict consistency guarantees, sure. Otherwise, don't piss off your API consumers, webhooks work just fine. Ahh, but all problems are queues. Wha
by toomuchtodo 5y ago
> If you need strict consistency guarantees, sure. Otherwise, don't piss off your API consumers, webhooks work just fine.
Ahh, but all problems are queues. What happens if your webhook destination is down and your source system sending queue backs up? What happens if your destination endpoint is up, providing 200s to requests, but throwing away the data quietly due to a mistake during a rollout? Or your webhook source quickly ramps to a volume that is effectively a DoS attack? (These are all problems I encountered in a role at a low code/no code product).
I strongly endorse others in this thread who indicate long polling events is a suitable pattern. You want the best worlds of data durability and consistency through polling functionality, but also as close to real time event firing as possible.
Of course, some APIs you have no control over, and are stuck building robust, chatty polling infra to support because your (paying) users demand access to those APIs. Such is the schlep.
- superbaconman 5y agoWhy do I need two different ways of retrieving events? Wouldn't the data also be available via the usual rest api? If events fail on the consumer end it's their responsibility to resync. Presumably code was written for an initial sync anyway no?