Interface NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder
- All Superinterfaces:
org.apache.camel.builder.EndpointProducerBuilder,org.apache.camel.EndpointProducerResolver
- All Known Subinterfaces:
NatsEndpointBuilderFactory.AdvancedNatsEndpointBuilder
- Enclosing interface:
NatsEndpointBuilderFactory
public static interface NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder
extends org.apache.camel.builder.EndpointProducerBuilder
Advanced builder for endpoint producers for the Nats component.
-
Method Summary
Modifier and TypeMethodDescriptionbasic()connection(io.nats.client.Connection connection) Reference an already instantiated connection to Nats server.connection(String connection) Reference an already instantiated connection to Nats server.consumerConfiguration(io.nats.client.api.ConsumerConfiguration consumerConfiguration) Sets a custom ConsumerConfiguration object for the JetStream consumer.consumerConfiguration(String consumerConfiguration) Sets a custom ConsumerConfiguration object for the JetStream consumer.durableName(String durableName) Sets the name to assign to the JetStream durable consumer.headerFilterStrategy(String headerFilterStrategy) To use a custom header filter strategy.headerFilterStrategy(org.apache.camel.spi.HeaderFilterStrategy headerFilterStrategy) To use a custom header filter strategy.jetstreamAsync(boolean jetstreamAsync) Sets whether to operate JetStream requests asynchronously.jetstreamAsync(String jetstreamAsync) Sets whether to operate JetStream requests asynchronously.lazyStartProducer(boolean lazyStartProducer) Whether the producer should be started lazy (on the first message).lazyStartProducer(String lazyStartProducer) Whether the producer should be started lazy (on the first message).pullSubscription(boolean pullSubscription) Sets the consumer subscription type for JetStream.pullSubscription(String pullSubscription) Sets the consumer subscription type for JetStream.traceConnection(boolean traceConnection) Whether or not connection trace messages should be printed to standard out for fine grained debugging of connection issues.traceConnection(String traceConnection) Whether or not connection trace messages should be printed to standard out for fine grained debugging of connection issues.Methods inherited from interface org.apache.camel.builder.EndpointProducerBuilder
doSetMultiValueProperties, doSetMultiValueProperty, doSetProperty, expr, getRawUriMethods inherited from interface org.apache.camel.EndpointProducerResolver
resolve, resolve
-
Method Details
-
basic
-
lazyStartProducer
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder lazyStartProducer(boolean lazyStartProducer) Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing. The option is a:booleantype. Default: false Group: producer (advanced)- Parameters:
lazyStartProducer- the value to set- Returns:
- the dsl builder
-
lazyStartProducer
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder lazyStartProducer(String lazyStartProducer) Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing. The option will be converted to abooleantype. Default: false Group: producer (advanced)- Parameters:
lazyStartProducer- the value to set- Returns:
- the dsl builder
-
connection
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder connection(io.nats.client.Connection connection) Reference an already instantiated connection to Nats server. The option is a:io.nats.client.Connectiontype. Group: advanced- Parameters:
connection- the value to set- Returns:
- the dsl builder
-
connection
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder connection(String connection) Reference an already instantiated connection to Nats server. The option will be converted to aio.nats.client.Connectiontype. Group: advanced- Parameters:
connection- the value to set- Returns:
- the dsl builder
-
consumerConfiguration
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder consumerConfiguration(io.nats.client.api.ConsumerConfiguration consumerConfiguration) Sets a custom ConsumerConfiguration object for the JetStream consumer. This is an advanced option typically used when you need to configure properties not exposed as simple Camel URI parameters. When set, this object will be used to build the final consumer subscription options. The option is a:io.nats.client.api.ConsumerConfigurationtype. Group: advanced- Parameters:
consumerConfiguration- the value to set- Returns:
- the dsl builder
-
consumerConfiguration
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder consumerConfiguration(String consumerConfiguration) Sets a custom ConsumerConfiguration object for the JetStream consumer. This is an advanced option typically used when you need to configure properties not exposed as simple Camel URI parameters. When set, this object will be used to build the final consumer subscription options. The option will be converted to aio.nats.client.api.ConsumerConfigurationtype. Group: advanced- Parameters:
consumerConfiguration- the value to set- Returns:
- the dsl builder
-
durableName
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder durableName(String durableName) Sets the name to assign to the JetStream durable consumer. Setting this value makes the consumer durable. The value is used to set the durable() field in the underlying NATS ConsumerConfiguration.Builder. The option is a:java.lang.Stringtype. Group: advanced- Parameters:
durableName- the value to set- Returns:
- the dsl builder
-
headerFilterStrategy
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder headerFilterStrategy(org.apache.camel.spi.HeaderFilterStrategy headerFilterStrategy) To use a custom header filter strategy. The option is a:org.apache.camel.spi.HeaderFilterStrategytype. Group: advanced- Parameters:
headerFilterStrategy- the value to set- Returns:
- the dsl builder
-
headerFilterStrategy
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder headerFilterStrategy(String headerFilterStrategy) To use a custom header filter strategy. The option will be converted to aorg.apache.camel.spi.HeaderFilterStrategytype. Group: advanced- Parameters:
headerFilterStrategy- the value to set- Returns:
- the dsl builder
-
jetstreamAsync
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder jetstreamAsync(boolean jetstreamAsync) Sets whether to operate JetStream requests asynchronously. The option is a:booleantype. Default: true Group: advanced- Parameters:
jetstreamAsync- the value to set- Returns:
- the dsl builder
-
jetstreamAsync
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder jetstreamAsync(String jetstreamAsync) Sets whether to operate JetStream requests asynchronously. The option will be converted to abooleantype. Default: true Group: advanced- Parameters:
jetstreamAsync- the value to set- Returns:
- the dsl builder
-
pullSubscription
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder pullSubscription(boolean pullSubscription) Sets the consumer subscription type for JetStream. Set to true to use a Pull Subscription (consumer explicitly requests messages). Set to false to use a Push Subscription (messages are automatically delivered). The option is a:booleantype. Default: true Group: advanced- Parameters:
pullSubscription- the value to set- Returns:
- the dsl builder
-
pullSubscription
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder pullSubscription(String pullSubscription) Sets the consumer subscription type for JetStream. Set to true to use a Pull Subscription (consumer explicitly requests messages). Set to false to use a Push Subscription (messages are automatically delivered). The option will be converted to abooleantype. Default: true Group: advanced- Parameters:
pullSubscription- the value to set- Returns:
- the dsl builder
-
traceConnection
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder traceConnection(boolean traceConnection) Whether or not connection trace messages should be printed to standard out for fine grained debugging of connection issues. The option is a:booleantype. Default: false Group: advanced- Parameters:
traceConnection- the value to set- Returns:
- the dsl builder
-
traceConnection
default NatsEndpointBuilderFactory.AdvancedNatsEndpointProducerBuilder traceConnection(String traceConnection) Whether or not connection trace messages should be printed to standard out for fine grained debugging of connection issues. The option will be converted to abooleantype. Default: false Group: advanced- Parameters:
traceConnection- the value to set- Returns:
- the dsl builder
-