Package com.rabbitmq.stream
Interface ConsumerBuilder.FlowConfiguration
- Enclosing interface:
ConsumerBuilder
public static interface ConsumerBuilder.FlowConfiguration
Message flow configuration.
The default configuration uses ConsumerFlowStrategy.creditOnChunkArrival()
.
- Since:
- 0.11.0
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionbuilder()
Go back to the builder.initialCredits
(int initialCredits) The number of initial credits for the subscription.strategy
(ConsumerFlowStrategy strategy) Flow strategy to use
-
Method Details
-
initialCredits
The number of initial credits for the subscription.Default is 10.
This calls uses
ConsumerFlowStrategy.creditOnChunkArrival(int)
.Use a small value like 1 for streams with large chunks (several hundreds of messages per chunk) and higher values (5 or more) for streams with small chunks (1 or a few messages per chunk).
- Parameters:
initialCredits
- the number of initial credits- Returns:
- this configuration instance
- See Also:
-
strategy
Flow strategy to use- Parameters:
strategy
- the strategy to use- Returns:
- this configuration instance
- Since:
- 0.12.0
- See Also:
-
builder
ConsumerBuilder builder()Go back to the builder.- Returns:
- the consumer builder
-