DEV Community

How To Build an Event Sourcing Pattern in Rails from Scratch

Isa Levine on May 03, 2020

All code from this demo can be found in this GitHub repo: https://github.com/isalevine/event-sourcing-user-app To Recap: What is Event Sou...
Collapse
 
matiasgarcia profile image
Matías Hernán García

Great article!

Dumb question. Probably this is left out due that the focus is about showing how an evented system can be built.

  1. What about validations at the moment of running the create event?
  2. I mean, what if a user submits, twice, to create a given user? How they will get feedback that that went wrong?
Collapse
 
thatjsdev profile image
Nishant Mendiratta

Hi Isa, thanks for sharing this insightful article. I'm still a noob in rails but this was really helpful. cheers.

Note: There is a typo, app/models/events/user/destroy.rb should be destroyed.rb.

Collapse
 
isalevine profile image
Isa Levine

Thank you Nishant, and great catch! Code samples and the Github repo have been updated. :)

Collapse
 
chuylerma profile image
chuylerma

I followed up the whole series (2 at this moment) I really enjoyed, and I'm sure that this is going to help me a lot. Thank you so much for sharing!