- java.lang.Object
-
- mutiny.zero.TubeConfiguration
-
public final class TubeConfiguration extends java.lang.ObjectConfiguration object for creatingTubethroughZeroPublisher.create(TubeConfiguration, Consumer).
-
-
Constructor Summary
Constructors Constructor Description TubeConfiguration()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BackpressureStrategygetBackpressureStrategy()Get the back-pressure strategy.intgetBufferSize()Get the buffer size.TubeConfigurationwithBackpressureStrategy(BackpressureStrategy strategy)Specify the back-pressure strategy, cannot benull.TubeConfigurationwithBufferSize(int bufferSize)Specify the buffer size must be strictly positive whenbackpressureStrategyis one ofBackpressureStrategy.BUFFERandBackpressureStrategy.LATEST.
-
-
-
Method Detail
-
withBackpressureStrategy
public TubeConfiguration withBackpressureStrategy(BackpressureStrategy strategy)
Specify the back-pressure strategy, cannot benull. The default isBackpressureStrategy.DROP.- Parameters:
strategy- the back-pressure strategy- Returns:
- this configuration
-
withBufferSize
public TubeConfiguration withBufferSize(int bufferSize)
Specify the buffer size must be strictly positive whenbackpressureStrategyis one ofBackpressureStrategy.BUFFERandBackpressureStrategy.LATEST. The default is-1.- Parameters:
bufferSize- the buffer size- Returns:
- this configuration
-
getBackpressureStrategy
public BackpressureStrategy getBackpressureStrategy()
Get the back-pressure strategy.- Returns:
- the back-pressure strategy
-
getBufferSize
public int getBufferSize()
Get the buffer size.- Returns:
- the buffer size
-
-