What could be the lightest memory- and CPU-wise combination of snapshot plugin and event store?

227 views Asked by At

We are using Akka Persistence for POC for an internal metrics gathering server solution. At this time we want to stay as light (memory and CPU-wise) as possible. We are using inmemory journal and file snapshots. Everything works, the only problem we have is the number of snapshots we're having. We are already removing all except the last snapshot (per persistence actor, of course), but the number of files is still too big (we are creating a lot of actors).

So, are there any suggestions what is the best combination of snapshot plugin/event store which will still make us stay light?

  • H2/Derby + JDBC?
  • local MongoDB with --smallfiles?
  • trying to use embedded Mongo in some way (all I have seen so far is for testing purposes only, not sure of it is stable enough)?
  • some other idea?

Please note, we don't plan on going distributed for now, the performance tests are giving us good enough numbers for our use case, so staying on the same machine is suitable and should be enough.

1

There are 1 answers

3
hicolour On BEST ANSWER

If only snapshot or store size is your concern, you should consider following:

  1. Optimize the data stored as journal event / snapshot
  2. Use serializer supporting compression kryo / akka-kryo-serialization
  3. Choose the data store which supports compression (eg. cassandra ) and its appropriate plugin akka-persistence-cassandra

Of course all of this may affect performance.