Class ThresholdActor<T>
- java.lang.Object
-
- org.apache.activemq.artemis.utils.actors.HandlerBase
-
- org.apache.activemq.artemis.utils.actors.ProcessorBase<java.lang.Object>
-
- org.apache.activemq.artemis.utils.actors.ThresholdActor<T>
-
public class ThresholdActor<T> extends ProcessorBase<java.lang.Object>
-
-
Field Summary
-
Fields inherited from class org.apache.activemq.artemis.utils.actors.ProcessorBase
STATE_FORCED_SHUTDOWN, STATE_NOT_RUNNING, STATE_RUNNING, tasks
-
-
Constructor Summary
Constructors Constructor Description ThresholdActor(java.util.concurrent.Executor parent, ActorListener<T> listener, int maxSize, java.util.function.ToIntFunction<T> sizeGetter, java.lang.Runnable overThreshold, java.lang.Runnable clearThreshold)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidact(T message)protected voiddoTask(java.lang.Object task)voidflush()-
Methods inherited from class org.apache.activemq.artemis.utils.actors.ProcessorBase
flush, isFlushed, remaining, shutdown, shutdown, shutdownNow, status, task
-
Methods inherited from class org.apache.activemq.artemis.utils.actors.HandlerBase
enter, inHandler, leave
-
-
-
-
Constructor Detail
-
ThresholdActor
public ThresholdActor(java.util.concurrent.Executor parent, ActorListener<T> listener, int maxSize, java.util.function.ToIntFunction<T> sizeGetter, java.lang.Runnable overThreshold, java.lang.Runnable clearThreshold)
-
-
Method Detail
-
doTask
protected final void doTask(java.lang.Object task)
- Specified by:
doTaskin classProcessorBase<java.lang.Object>
-
act
public void act(T message)
-
flush
public void flush()
-
-