I’ve noticed that duplicate (those already acknowledged) events can be sent to a connected client on a restart of ES and subsequent reload of a competing consumer checkpoint.
Is is possible within the client to identify that the events has previously been sent and acknowledged?
Subscription client receives the VoucherPurchasedEvent and sends an email/sms to the user to confirm purchase
Sounds like our subscription client needs to be smarter and keep track of which events have already been handled such that duplicate email/sms messages are not sent.
What’s the difference between 1 & 2?
I would argue that if 2 hasn’t happened, 1 hasn’t happened.
Wouldn’t your subscription client already need to know it’s position in the stream?
You’re not going to be able to save the checkpoint atomically with sending the email, but measure the size of that risk and the impact of a duplicate email. Sounds minor to me.
"Sounds like our subscription client needs to be smarter and keep
track of which events have already been handled such that duplicate
email/sms messages are not sent."