Closed gregoryyoung closed 9 years ago
Hi man! I'm really proud that you've starred my project. Cool to see you here :)
Yes, you're absolutely right. I should probably reword description. I do provide duplicate event detection feature which could be used by users to implement idempotence but writes are not automatically idempotent.
The user will get back DuplicateEventException
if the event with the same id was previously stored. The offending event will be passed as the payload of exception. The user could then remove it from batch and retry (or just cancel).
I made the choice to implement it this way due to the following reasons:
I think it's important for end-user to be aware of duplicates. The high rate of duplicates could mean a severe problem somewhere else, and that better be checked.
P.S. I don't even have the test for 2,7,2. I should probably add it :smile:
Forgot to mention. That behavior is illustrated here https://github.com/yevhen/Streamstone/blob/master/Source/Example/Scenarios/S09_Handling_duplicates.cs
This code just feels so weird for me in terms of calling it idempotency can I make it more fun and throw an IdempotencyException? :)
On Wed, Jun 3, 2015 at 5:47 PM, Yevhen Bobrov notifications@github.com wrote:
Forgot to mention. That behavior is illustrated here https://github.com/yevhen/Streamstone/blob/master/Source/Example/Scenarios/S09_Handling_duplicates.cs
— Reply to this email directly or view it on GitHub https://github.com/yevhen/Streamstone/issues/11#issuecomment-108465690.
Studying for the Turing test
Well, the code looks absolutely legitimate but the message is not :smile:
No worries, I'll change it appropriately to not confuse the people.
@gregoryyoung thanks, your feedback is incredibly important for me! Would be happy to see more issues spotted by 'the godfather' :+1:
P.S. This project is really young :blush:
@gregoryyoung does it make more sense now? May I close this issue? :smile:
Yep go for it. I think its just an expectation mismatch :)
On Wed, Jun 3, 2015 at 7:41 PM, Yevhen Bobrov notifications@github.com wrote:
@gregoryyoung https://github.com/gregoryyoung does it make more sense now? May I close this issue? [image: :smile:]
— Reply to this email directly or view it on GitHub https://github.com/yevhen/Streamstone/issues/11#issuecomment-108517602.
Studying for the Turing test
Cool. Thanks, man!
I am not finding any tests on some of the bizarre edge conditions that happen around idempotency. As an example:
I write in a batch events 1,3,7 I then write a batch 2,7,14
Is this really an idempotent write? or is it an error.