Class LogStreamManager
java.lang.Object
org.nuxeo.lib.stream.computation.log.LogStreamManager
- All Implemented Interfaces:
AutoCloseable,StreamManager
StreamManager based on a LogManager
- Since:
- 11.1
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final Map<Name,RecordFilterChain> protected final LogManagerstatic final Stringprotected final Map<String,StreamProcessor> static final String -
Constructor Summary
ConstructorsConstructorDescriptionLogStreamManager(String nodeId, LogManager logManager) LogStreamManager(LogManager logManager) -
Method Summary
Modifier and TypeMethodDescriptionAppends a record to a processor's source stream.voidclose()createStreamProcessor(String processorName) Creates a registered processor without starting it.createTailer(Name computationName, Collection<LogPartition> streamPartitions) getCodec(Collection<Name> streams) protected StringgetProcessor(String processorName) Gets a processor.Gets a set of processor names.protected voidinitAppenders(Collection<String> streams, Settings settings) protected voidinitInternalStream(Name stream) protected voidprotected voidinitStream(String streamName, Settings settings) protected voidinitStreams(Topology topology, Settings settings) voidRegisters a processor and initializes the underlying streams, this is needed before creating a processor or appending record in source streams.voidRegisters some source Streams without any processors.protected voidregisterFilters(Collection<String> streams, Settings settings) subscribe(Name computationName, Collection<Name> streams, RebalanceListener listener) booleanDeprecated.booleansupportSubscribe(Name stream) Returnstrueif thesubscribe(org.nuxeo.lib.stream.log.Name, java.util.Collection<org.nuxeo.lib.stream.log.Name>, org.nuxeo.lib.stream.log.RebalanceListener)method is supported for the specific stream.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.nuxeo.lib.stream.computation.StreamManager
registerAndCreateProcessor
-
Field Details
-
PROCESSORS_STREAM
- See Also:
-
METRICS_STREAM
- See Also:
-
INTERNAL_CODEC
-
logManager
-
systemMetadata
-
processors
-
topologies
-
settings
-
filters
-
streams
-
-
Constructor Details
-
LogStreamManager
-
LogStreamManager
-
-
Method Details
-
initInternalStreams
protected void initInternalStreams() -
initInternalStream
-
register
Description copied from interface:StreamManagerRegisters a processor and initializes the underlying streams, this is needed before creating a processor or appending record in source streams.- Specified by:
registerin interfaceStreamManager
-
register
Description copied from interface:StreamManagerRegisters some source Streams without any processors.- Specified by:
registerin interfaceStreamManager
-
createStreamProcessor
Description copied from interface:StreamManagerCreates a registered processor without starting it.- Specified by:
createStreamProcessorin interfaceStreamManager
-
getNodeId
-
getLogManager
-
append
Description copied from interface:StreamManagerAppends a record to a processor's source stream.- Specified by:
appendin interfaceStreamManager
-
getProcessorNames
Description copied from interface:StreamManagerGets a set of processor names.- Specified by:
getProcessorNamesin interfaceStreamManager
-
getProcessor
Description copied from interface:StreamManagerGets a processor.- Specified by:
getProcessorin interfaceStreamManager- Returns:
- null if the processor doesn't exist
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceStreamManager
-
supportSubscribe
Returnstrueif thesubscribe(org.nuxeo.lib.stream.log.Name, java.util.Collection<org.nuxeo.lib.stream.log.Name>, org.nuxeo.lib.stream.log.RebalanceListener)method is supported for the specific stream.- Since:
- 2021.34
-
supportSubscribe
public boolean supportSubscribe()Deprecated.since 2021.34 usesupportSubscribe(Name)insteadReturnstrueif thesubscribe(org.nuxeo.lib.stream.log.Name, java.util.Collection<org.nuxeo.lib.stream.log.Name>, org.nuxeo.lib.stream.log.RebalanceListener)method is supported. Now deprecated because some implementations support subscribe only on specific streams. -
subscribe
public LogTailer<Record> subscribe(Name computationName, Collection<Name> streams, RebalanceListener listener) -
createTailer
public LogTailer<Record> createTailer(Name computationName, Collection<LogPartition> streamPartitions) -
getFilter
-
getCodec
-
initStreams
-
initStream
-
initAppenders
-
registerFilters
-
supportSubscribe(Name)instead