3 ms·
I encountered that problem. The ad hoc fix, was to have a version field in each event and functions that translate the old event into new event(s). The code tha
by coolio222 9y ago
I encountered that problem. The ad hoc fix, was to have a version field in each event and functions that translate the old event into new event(s). The code that processes the events only processes events of the current version.
If your old events had been denormalized this might result into repetition of events when splitted.
- daddykotex 9y agoOk, thanks for the pointer
- Joeri 9y agoTo add to that, you can treat it like you would schema migration on databases: implement v1 to v2, v2 to v3, etc... and replay the migrations in order to migrate from whatever version of the event is to the latest version. This allows keeping event migration code as immutable as the event versions it migrates between.