Examples1. When I wanted to improve the Spaced Repetition  algorithm, I needed the information how long the last and longest period of remembering a topic was and for which length of period the learner had failed to remember in the past and how often this ha happened. The Event-Store already contained each event of the learner answering the quizzes, including whether it was correct or wrong and a time stamp, thus all I had to do, was to extend the read-model-builder to extract this information on a per-topic level. 2. Another day I want to extend a multiple choice game where I wanted to confront the learner with terms which he had confused in earlier exercises. The app once knew about which answers were given wrong but I did not store this data, as I had no use for it at that time. Thus, the information was lost for past events; all I could do was to start storing this data along with new events.
ConclusionEvent-Sourcing is a great preparation for new requirements, but only if you are smart enough to store all data along with the events, which belong to the business case from which it stems. Just not needing the data at that time should not be a reason, not to store it. You can omit it in your read-models as long as it's not needed, but once it is needed, you can simply add it to the reducers - et voilá - your application can use it.
Legal NoteOne warning, though: Data privacy laws might prohibit storing data which is not actually needed (at the time of storing the data). his principle is called "data avoidance" or "data minimization" (in German: "Datensparsamkeit"). But that only applies to personal data and in most cases can be legalized by putting the rules into your terms of usage. Ask your lawyer for more details!
Comments?If you like, you can leave a comment on Twitter, thanks!
 https://gleanius.com  Event Sourcing is an Software Pattern where all changes to the state of a software system are recorded as events as a primary data source in a way that it's possible to re-create any past state of the software system.  CQRS (Command query responsibility segregation) is a design principle which uses separate data-structures to update and and modify data.  To be honest, my usage of this pattern in Gleanius is limited to the app internals so far, as I've not yet implemented any server-side queries except a full restore.  An Event-Store is a software module which stores immutable events in the context of Event-Sourcing.  Spaced Repetition is a learning technique that applies increasing intervals of time between subsequent review of previously learned material in order to make learning more efficient.