Interface StubComponentBuilderFactory.StubComponentBuilder
-
- All Superinterfaces:
ComponentBuilder<org.apache.camel.component.stub.StubComponent>
- All Known Implementing Classes:
StubComponentBuilderFactory.StubComponentBuilderImpl
- Enclosing interface:
- StubComponentBuilderFactory
public static interface StubComponentBuilderFactory.StubComponentBuilder extends ComponentBuilder<org.apache.camel.component.stub.StubComponent>
Builder for the Stub component.
-
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default StubComponentBuilderFactory.StubComponentBuilder
autowiredEnabled(boolean autowiredEnabled)
Whether autowiring is enabled.default StubComponentBuilderFactory.StubComponentBuilder
bridgeErrorHandler(boolean bridgeErrorHandler)
Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler.default StubComponentBuilderFactory.StubComponentBuilder
concurrentConsumers(int concurrentConsumers)
Sets the default number of concurrent threads processing exchanges.default StubComponentBuilderFactory.StubComponentBuilder
defaultBlockWhenFull(boolean defaultBlockWhenFull)
Whether a thread that sends messages to a full SEDA queue will block until the queue's capacity is no longer exhausted.default StubComponentBuilderFactory.StubComponentBuilder
defaultDiscardWhenFull(boolean defaultDiscardWhenFull)
Whether a thread that sends messages to a full SEDA queue will be discarded.default StubComponentBuilderFactory.StubComponentBuilder
defaultOfferTimeout(long defaultOfferTimeout)
Whether a thread that sends messages to a full SEDA queue will block until the queue's capacity is no longer exhausted.default StubComponentBuilderFactory.StubComponentBuilder
defaultPollTimeout(int defaultPollTimeout)
The timeout (in milliseconds) used when polling.default StubComponentBuilderFactory.StubComponentBuilder
defaultQueueFactory(org.apache.camel.component.seda.BlockingQueueFactory<org.apache.camel.Exchange> defaultQueueFactory)
Sets the default queue factory.default StubComponentBuilderFactory.StubComponentBuilder
lazyStartProducer(boolean lazyStartProducer)
Whether the producer should be started lazy (on the first message).default StubComponentBuilderFactory.StubComponentBuilder
queueSize(int queueSize)
Sets the default maximum capacity of the SEDA queue (i.e., the number of messages it can hold).default StubComponentBuilderFactory.StubComponentBuilder
shadow(boolean shadow)
If shadow is enabled then the stub component will register a shadow endpoint with the actual uri that refers to the stub endpoint, meaning you can lookup the endpoint via both stub:kafka:cheese and kafka:cheese.-
Methods inherited from interface org.apache.camel.builder.component.ComponentBuilder
build, build, doSetProperty, register
-
-
-
-
Method Detail
-
shadow
default StubComponentBuilderFactory.StubComponentBuilder shadow(boolean shadow)
If shadow is enabled then the stub component will register a shadow endpoint with the actual uri that refers to the stub endpoint, meaning you can lookup the endpoint via both stub:kafka:cheese and kafka:cheese. The option is a: <code>boolean</code> type. Default: false Group: common- Parameters:
shadow
- the value to set- Returns:
- the dsl builder
-
bridgeErrorHandler
default StubComponentBuilderFactory.StubComponentBuilder bridgeErrorHandler(boolean bridgeErrorHandler)
Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions, that will be logged at WARN or ERROR level and ignored. The option is a: <code>boolean</code> type. Default: false Group: consumer- Parameters:
bridgeErrorHandler
- the value to set- Returns:
- the dsl builder
-
concurrentConsumers
default StubComponentBuilderFactory.StubComponentBuilder concurrentConsumers(int concurrentConsumers)
Sets the default number of concurrent threads processing exchanges. The option is a: <code>int</code> type. Default: 1 Group: consumer- Parameters:
concurrentConsumers
- the value to set- Returns:
- the dsl builder
-
defaultPollTimeout
default StubComponentBuilderFactory.StubComponentBuilder defaultPollTimeout(int defaultPollTimeout)
The timeout (in milliseconds) used when polling. When a timeout occurs, the consumer can check whether it is allowed to continue running. Setting a lower value allows the consumer to react more quickly upon shutdown. The option is a: <code>int</code> type. Default: 1000 Group: consumer (advanced)- Parameters:
defaultPollTimeout
- the value to set- Returns:
- the dsl builder
-
defaultBlockWhenFull
default StubComponentBuilderFactory.StubComponentBuilder defaultBlockWhenFull(boolean defaultBlockWhenFull)
Whether a thread that sends messages to a full SEDA queue will block until the queue's capacity is no longer exhausted. By default, an exception will be thrown stating that the queue is full. By enabling this option, the calling thread will instead block and wait until the message can be accepted. The option is a: <code>boolean</code> type. Default: false Group: producer- Parameters:
defaultBlockWhenFull
- the value to set- Returns:
- the dsl builder
-
defaultDiscardWhenFull
default StubComponentBuilderFactory.StubComponentBuilder defaultDiscardWhenFull(boolean defaultDiscardWhenFull)
Whether a thread that sends messages to a full SEDA queue will be discarded. By default, an exception will be thrown stating that the queue is full. By enabling this option, the calling thread will give up sending and continue, meaning that the message was not sent to the SEDA queue. The option is a: <code>boolean</code> type. Default: false Group: producer- Parameters:
defaultDiscardWhenFull
- the value to set- Returns:
- the dsl builder
-
defaultOfferTimeout
default StubComponentBuilderFactory.StubComponentBuilder defaultOfferTimeout(long defaultOfferTimeout)
Whether a thread that sends messages to a full SEDA queue will block until the queue's capacity is no longer exhausted. By default, an exception will be thrown stating that the queue is full. By enabling this option, where a configured timeout can be added to the block case. Utilizing the .offer(timeout) method of the underlining java queue. The option is a: <code>long</code> type. Group: producer- Parameters:
defaultOfferTimeout
- the value to set- Returns:
- the dsl builder
-
lazyStartProducer
default StubComponentBuilderFactory.StubComponentBuilder 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: <code>boolean</code> type. Default: false Group: producer- Parameters:
lazyStartProducer
- the value to set- Returns:
- the dsl builder
-
autowiredEnabled
default StubComponentBuilderFactory.StubComponentBuilder autowiredEnabled(boolean autowiredEnabled)
Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc. The option is a: <code>boolean</code> type. Default: true Group: advanced- Parameters:
autowiredEnabled
- the value to set- Returns:
- the dsl builder
-
defaultQueueFactory
default StubComponentBuilderFactory.StubComponentBuilder defaultQueueFactory(org.apache.camel.component.seda.BlockingQueueFactory<org.apache.camel.Exchange> defaultQueueFactory)
Sets the default queue factory. The option is a: <code>org.apache.camel.component.seda.BlockingQueueFactory<org.apache.camel.Exchange></code> type. Group: advanced- Parameters:
defaultQueueFactory
- the value to set- Returns:
- the dsl builder
-
queueSize
default StubComponentBuilderFactory.StubComponentBuilder queueSize(int queueSize)
Sets the default maximum capacity of the SEDA queue (i.e., the number of messages it can hold). The option is a: <code>int</code> type. Default: 1000 Group: advanced- Parameters:
queueSize
- the value to set- Returns:
- the dsl builder
-
-