Hi, We have been using axon for our cqrs based microservice applications since more than a year now. We currently have one of the bounded context with more than half a million events in its event store and still growing. Since the event store seems to be too huge we are looking for approaches to archive events to improve performance and reduce event store size. We currently thought of the below approach.
Having to force create snapshots for all the aggregates and then archive the existing events outside the database in a compressed format etc. Since we have the snapshots for every aggregate it would load up from the snapshot initially after the archiving. The events created from then on will still be in the event store and we can repeat the cycle every 500k events etc. In case we have any aggregate structure changes or in case we face a scenario where in we need to replay all older archived events we can load up the events store with the archived events when ever needed and create updated snapshots. The aggregate structure changes would not occur very often and is very rare scenario.
It would be great if I can get suggestions regarding the downside if any for this approach, side effects or a better approach if available.
FYI: We are using MongoDB and also trackingtokens for query side.