Package org.graylog2.streams
Class StreamRouterEngine
java.lang.Object
org.graylog2.streams.StreamRouterEngine
Stream routing engine to select matching streams for a message.
This class is NOT thread-safe! Use one instance per thread.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
static class
Contains matching results for a stream. -
Constructor Summary
ConstructorDescriptionStreamRouterEngine
(List<Stream> streams, ExecutorService executorService, StreamFaultManager streamFaultManager, StreamMetrics streamMetrics, javax.inject.Provider<Stream> defaultStreamProvider, com.codahale.metrics.MetricRegistry metricRegistry) -
Method Summary
Modifier and TypeMethodDescriptionReturns the fingerprint of the engine instance.Returns the list of streams that are processed by the engine.Returns a list of matching streams for the given message.Returns a list of stream rule matches.
-
Constructor Details
-
StreamRouterEngine
@Inject public StreamRouterEngine(List<Stream> streams, ExecutorService executorService, StreamFaultManager streamFaultManager, StreamMetrics streamMetrics, javax.inject.Provider<Stream> defaultStreamProvider, com.codahale.metrics.MetricRegistry metricRegistry)
-
-
Method Details
-
getStreams
Returns the list of streams that are processed by the engine.- Returns:
- the list of streams
-
getFingerprint
Returns the fingerprint of the engine instance.- Returns:
- the fingerprint
-
match
Returns a list of matching streams for the given message.- Parameters:
message
- the message- Returns:
- the list of matching streams
-
testMatch
Returns a list of stream rule matches. Can be used to test streams and stream rule matches. This is meant for testing, do NOT use in production processing pipeline! (usematch
instead)- Parameters:
message
- the message to match streams on
-