Last week Dave Foley, our CTO, spoke at CascadiaJS in Vancouver, BC, on the topic "Event is the New Model." The conference organizers have posted video of the talk, which you can watch below.
Here's Dave's abstract of his presentation:
Most of us are accustomed to modeling our application domains by their state at any given point in time. When audit logs, reporting views, data migrations and real-time updates are required, our tendency is to bolt them on to this relational point-in-time model, which can be difficult and costly.
Building on the Event Sourcing pattern, we can instead treat each application as an append-only stream of immutable events. In this style of application, the state of the model at any point in time can be derived by replaying all of the events up to that point in time. This also allows for multiple point-in-time representations ("Models") to exist simultaneously in different places.
The Node.js ecosystem provides a particularly interesting platform for this style of application development. With a shared language between a browser-based client and a node-based server, we can even use the same model logic in both places. I'll walk through experiences and lessons learned over the course of the development of an event-sourced real-time browser application using node, socket.io, spine, and related technologies.