ismasan

@ismasan@ruby.social
70 Followers
85 Following
349 Posts
More #eventsourcing #ruby progress: this is using SQLite for the event store backend, and a "vibe-coded" 😳 Unix socket contraption for real-time pub/sub
Holy shit it looks like I got my Ruby event-sourcing library working with SQLite. This is promising!
And a (simulated) payment workflow that runs concurrently from order fulfilment
Why does the FulfillOrder command handler also check whether all items are fulfilled? Because that might have changed in the meantime. Eventual consistency is fun!
Many ways to do this, but the Order actor reacts to its own "ItemFulfilled" events, and if all line items have been fulfilled, then it schedules a command to fulfil itself.
A little (naive) order fulfilment flow for my Ruby event sourcing demo
Finishing the (long) day with the now classic time-travelling UI for my POS demo.
Status report.
I'm also extracting some common patterns into a library. Such as turning command structs into auto-validating forms, and eventually all the machinery for reactive UIs.
The start of a bare-bones event-sourced POS demo for an imaginary coffee-shop