aws-samples / aws-samples/transactional-outbox-pattern
How to scale horizontally?
Open
- Dominant language
- Java
- Stars
- 50
- Forks
- 5
- PR merge metrics
- No merged PRs in 30d
Description
How can I guarantee ordering by key (e.g., userId)?
For example, I must not send events for the same userId out of order.
If I have two events for user X, called A and B, I need to guarantee that A is sent first and B afterwards.
However, if I have two instances of the outbox processor, both could pick up events for the same userId. If, for any reason, one instance sends B before A, the ordering is broken.
What is the best practice or solution for this problem?
Contributor guide
Assessment
This issue has not been assessed yet.