public final class AgileWaitingStrategy extends Object implements com.lmax.disruptor.WaitStrategy, WaitingMood
Constructor and Description |
---|
AgileWaitingStrategy() |
AgileWaitingStrategy(com.lmax.disruptor.WaitStrategy slowWaitStrategy,
com.lmax.disruptor.WaitStrategy fastWaitStrategy) |
Modifier and Type | Method and Description |
---|---|
void |
calm()
Turn the mood into eco CPU demand mode to save resources from the underlying component.
|
com.lmax.disruptor.WaitStrategy |
current() |
void |
nervous()
Turn the mood into aggressive CPU demand mode to effectively give an an additional resources boost to the underlying
component.
|
void |
signalAllWhenBlocking() |
long |
waitFor(long sequence,
com.lmax.disruptor.Sequence cursor,
com.lmax.disruptor.Sequence dependentSequence,
com.lmax.disruptor.SequenceBarrier barrier) |
public AgileWaitingStrategy()
public AgileWaitingStrategy(com.lmax.disruptor.WaitStrategy slowWaitStrategy, com.lmax.disruptor.WaitStrategy fastWaitStrategy)
public long waitFor(long sequence, com.lmax.disruptor.Sequence cursor, com.lmax.disruptor.Sequence dependentSequence, com.lmax.disruptor.SequenceBarrier barrier) throws com.lmax.disruptor.AlertException, InterruptedException, com.lmax.disruptor.TimeoutException
waitFor
in interface com.lmax.disruptor.WaitStrategy
com.lmax.disruptor.AlertException
InterruptedException
com.lmax.disruptor.TimeoutException
public void signalAllWhenBlocking()
signalAllWhenBlocking
in interface com.lmax.disruptor.WaitStrategy
public void nervous()
WaitingMood
nervous
in interface WaitingMood
public void calm()
WaitingMood
calm
in interface WaitingMood
public com.lmax.disruptor.WaitStrategy current()
Copyright © 2016. All rights reserved.