Class ProducerPool<M extends Message>
java.lang.Object
org.nuxeo.lib.stream.pattern.consumer.internals.AbstractCallablePool<ProducerStatus>
org.nuxeo.lib.stream.pattern.producer.ProducerPool<M>
- All Implemented Interfaces:
AutoCloseable
A Pool of ProducerRunner
- Since:
- 9.1
-
Field Summary
Modifier and TypeFieldDescriptionprotected final ProducerFactory<M>
protected final String
protected final LogManager
Fields inherited from class org.nuxeo.lib.stream.pattern.consumer.internals.AbstractCallablePool
nbThreads, supplyThreadPool, threadPool
-
Constructor Summary
ConstructorDescriptionProducerPool
(String logName, LogManager manager, Codec<M> codec, ProducerFactory<M> factory, short nbThreads) ProducerPool
(String logName, LogManager manager, ProducerFactory<M> factory, short nbThreads) Deprecated. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
afterCall
(List<ProducerStatus> ret) protected Callable<ProducerStatus>
getCallable
(int i) protected ProducerStatus
Value to return when there was an exception during executionprotected String
Methods inherited from class org.nuxeo.lib.stream.pattern.consumer.internals.AbstractCallablePool
close, getNbThreads, runPool, start
-
Field Details
-
manager
-
logName
-
codec
-
factory
-
-
Constructor Details
-
ProducerPool
@Deprecated public ProducerPool(String logName, LogManager manager, ProducerFactory<M> factory, short nbThreads) Deprecated.since 11.1, due to serialization issue with java 11, useProducerPool(String, LogManager, Codec, ProducerFactory, short)
which allows to give acodec
toappender
. -
ProducerPool
public ProducerPool(String logName, LogManager manager, Codec<M> codec, ProducerFactory<M> factory, short nbThreads)
-
-
Method Details
-
getErrorStatus
Description copied from class:AbstractCallablePool
Value to return when there was an exception during execution- Specified by:
getErrorStatus
in classAbstractCallablePool<ProducerStatus>
-
getCallable
- Specified by:
getCallable
in classAbstractCallablePool<ProducerStatus>
-
getThreadPrefix
- Specified by:
getThreadPrefix
in classAbstractCallablePool<ProducerStatus>
-
afterCall
- Specified by:
afterCall
in classAbstractCallablePool<ProducerStatus>
-
ProducerPool(String, LogManager, Codec, ProducerFactory, short)
which allows to give acodec
toappender
.