So I'm developing this small engine that does a remote integration between two systems in order to sync data, both systems have webhooks for create & update events, and both have APIs (one is REST one is XML), so it is an event-based integration rather than a typical batch one.

My problem is that if System A creates an entry and fires a webhook that the engine catches, if the engine doesn't find it, then it creates a comparable entry in System B which triggers a create webhook, which then the engine catches as a new request... and you see my problem.

Same scenario could happen for an update webhook (actually this one is more likely to happen).

I'm guessing I'm not the first person on the earth to encounter this problem, so I'm wondering what would be an elegant way of handling this given that I cannot modify the APIs, nor inject custom metadata in the messages that could help me catch the loop.

FYI, the integration is between two issue tracking systems.

  • I understand that you are describing an infinite loop, but I don't exactly understand how you can get into this situation. Is it possible to add a TTL so that the loop will die after N iterations? Please explain more
    – benathon
    Commented Dec 3, 2013 at 0:54

1 Answer 1


Add a globally unique identifier (GUID) to every issue. Make sure both systems track these IDs. When a system receives a "New issue added" event it will first look up the GUID - if it exists in its own database then it can ignore the event.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.