Query Plugin

It implements the following Persistence Queries:

  • eventsByPersistenceId, currentEventsByPersistenceId
  • eventsByTag, currentEventsByTag
  • persistenceIds, currentPersistenceIds

See API details in CassandraReadJournalCassandraReadJournal and eventsByTag documentation.

Persistence Query usage example to obtain a stream with all events tagged with “someTag” with Persistence Query:

val queries = PersistenceQuery(system).readJournalFor[CassandraReadJournal](CassandraReadJournal.Identifier)
queries.eventsByTag("someTag", Offset.noOffset)

Configuration

The default settings can be changed with the configuration properties defined in reference.conf.

Query configuration is under akka.persistence.cassandra.query.

Events by tag configuration is under akka.persistence.cassandra.events-by-tag and shared by journal and query.

If using events by tag query it is important to set the first time bucket

Found an error in this documentation? The source code for this page can be found here. Please feel free to edit and contribute a pull request.