Daily Thought - 2024-04-21
Hey, I'm Hanno! These are my daily thoughts on Crosscut, the programming language I'm creating. If you have any questions, comments, or feedback, please get in touch!
This thought was published before Crosscut was called Crosscut! If it refers to "Caterpillar", that is the old name, just so you know.
Event Sourcing is a software architecture in which every change to application state is encoded as a value, an event. These events are executed deterministically, so you can use them to reconstruct any past state. And if you add the required information to these events, you can also undo them, rewinding to an earlier state.
Over the last few days, I've been talking about how to step backwards through a Caterpillar program. If Event Sourcing is to play a role in supporting this, then the language runtime and debugger need to understand events. Where they are stored, how to apply them to application state, how to undo them. All of this implies a pretty close relationship between the Caterpillar runtime and an application.
The runtime would act more like a framework than a typical language runtime, which certainly wouldn't be a good fit for all use cases. But thanks to the platform concept, it could be optional. Maybe I can come up with an approach that allows applications to easily opt into event sourcing functionality when they want to improve their interactivity, without weighing down applications that don't need it.
Hey, you! Want to subscribe to my daily thoughts? Just let me know (maybe include a nice message, if you're up for it), and I'll send you an email whenever I post a new one.