package redis
Type Members
-
class
RedisJournal extends AsyncWriteJournal
Stores events inside a redis database.
Stores events inside a redis database.
For each persistence id
persistenceId, it creates two keys:journal:persisted:persistenceIdcontains a sorted set of events (sorted by sequence number)journal:persisted:persistenceId:highestSequenceNrcontains the highest sequence number
For each tag
t, it creates a keyjournal:tag:twhich contains the ordered list of pair (sequenceNr, persistenceId). Order in this list is the order in which events with the given tagtwere recorded.It also maintains following keys:
journal:persistenceIdswhich is a set of persistence identifiers.journal:tagswhich is the set of all tags.
Using the redis PubSub mechanism, this journal notifies whoever is interested on following channels:
journal:channel:idsany new persisted identifier is publishedjournal:channel:persisted:<id>anytime a new event is appended to a persistence id<id>, the sequenceNr is publishedjournal:channel:tagsanytime a new event is appended to a tag, the tag name is published