2
votes

I am having trouble figuring out if there is a way that I can set the keyspace of the cassandra-snapshot-store and cassandra-journal tables in Akka.net when using the Akka.Persistence.Cassandra plugin.

In my current setup, I have two separate keyspaces in Cassandra (one for each client) and I would like to keep their data and message histories separate.

As I understand it, these tables are created during the PreStart() methods of the CassandraJournal and CassandraSnapshotStore classes of the plugin.

I don't mind having a dummy keyspace for when the PreStart() methods are loaded but I would like to be able to change the keyspace once the system is up and running.

Any help on the matter would be greatly appreciated. Thanks!

1

1 Answers

0
votes

After looking into it a bit more, it looks like the akka.persistence.cassandra plugin does not support runtime switch of the space. It is also not possible to make it load different section of config using JournalPersistanceId and SnapshotPersistenceId properties of PersistenceActor because plugin itself always looks at the specific cassandra-journal and cassandra-snapshot-store sections and grabs keyspace from there. So I will have to come up with a different approach and perhaps change the way that I am segregating my data.