Package de.otto.synapse.messagestore
Class Indexers
java.lang.Object
de.otto.synapse.messagestore.Indexers
Utility class used to create
Indexer instances.-
Method Summary
Modifier and TypeMethodDescriptionstatic IndexerReturns an Indexer that is indexingTextMessagebyKey.partitionKey().static IndexerReturns a composite Indexer that is able to support several indexes.static IndexerReturns a composite Indexer that is able to support several indexes.static Indexerstatic Indexerstatic IndexeroriginIndexer(String origin) Returns an Indexer that is indexing all entries with static value that is identifying the origin of some message.static IndexerReturns an Indexer that is indexingTextMessagebyKey.partitionKey().static IndexerserviceInstanceIndexer(String serviceInstance) Returns an Indexer that is indexing all entries with static value that is identifying the service-instance that has added the message to theMessageStore.
-
Method Details
-
noOpIndexer
- Returns:
- no-op Indexer that is not doing anything.
-
composite
Returns a composite Indexer that is able to support several indexes.- Parameters:
indexers- the list of Indexers- Returns:
- composite Indexer
-
composite
Returns a composite Indexer that is able to support several indexes.- Parameters:
indexers- the list of Indexers- Returns:
- composite Indexer
-
originIndexer
Returns an Indexer that is indexing all entries with static value that is identifying the origin of some message.The origin can be the name of the service sending the message, or some other identifier like, for example 'Snapshot'.
- Parameters:
origin- the origin of the indexed message- Returns:
- origin indexer
-
serviceInstanceIndexer
Returns an Indexer that is indexing all entries with static value that is identifying the service-instance that has added the message to theMessageStore.In most cases, a
hostname:portorservice-name@hostname:portvalue is sufficient to identify the instance of some service- Parameters:
serviceInstance- a string identifying a single instance of a cluster.- Returns:
- serviceInstance indexer
-
partitionKeyIndexer
Returns an Indexer that is indexingTextMessagebyKey.partitionKey().- Returns:
- partition-key indexer
-
journalKeyIndexer
-
channelNameIndexer
Returns an Indexer that is indexingTextMessagebyKey.partitionKey().- Returns:
- partition-key indexer
-