3 ms·
There are ways to put some state outside the event stream that play nicely with the model. For example you could store the body in a content addressed store (a
by ithkuil 9y ago
There are ways to put some state outside the event stream that play nicely with the model.
For example you could store the body in a content addressed store (a key value store whose keys are hashes of the value). This preserves the ideal model of immutable events as you cannot accidentally change the content of the event since that would violate the property of the CAS. But nothing prevents you from deleting an entry in the CAS.
However you still have to find all the records you need to delete!
The trick with forgetting the encryption key let makes this step a O(1) operation.
On the other hand it forces you to decide upfront the granularity of ownership, i.e. if you treat payload deletion as a batch process you can deal with mistakes, change your mind about which data should or should not be deleted. While with the encryption technique, changing your mind would require you to perform a full history replay and reencrypt data in a new stream (and throw away the old one) with the new granularity model.