- Newest
- Most votes
- Most comments
Thanks for your response.
I was aware that a rule could be triggered multiple times. But here it is more that the event is fired two times. (maybe it means the same for AWS, but I think there is slight difference)
In any case make the lambdas idempotent should be the solution. As a best practice, for the unique id, is it better to use the id generated by event bridge or an id in the payload coming from our internal process ?
Thanks
I would recommend you make the idempotency in the payload of the message that can be identified by your internal systems.
This can happen in a large distributed system (which Amazon EventBridge is). See the documentation here: https://docs.aws.amazon.com/eventbridge/latest/userguide/eb-troubleshooting.html#eb-rule-triggered-more-than-once
A best practice is to make events idempotent, for more than this rare occurrence. You may need to replay events under some recovery scenarios. See the AWS Well-Architected Framework Best Practice, Make all responses idempotent.
Relevant content
- Accepted Answerasked 5 years ago
- Accepted Answerasked a year ago
- AWS OFFICIALUpdated 5 months ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 2 years ago
What was the event source?