Interface PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder
- All Superinterfaces:
org.apache.camel.builder.EndpointConsumerBuilder,org.apache.camel.EndpointConsumerResolver
- All Known Subinterfaces:
PulsarEndpointBuilderFactory.PulsarEndpointBuilder
- Enclosing interface:
- PulsarEndpointBuilderFactory
public static interface PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder
extends org.apache.camel.builder.EndpointConsumerBuilder
Builder for endpoint consumers for the Pulsar component.
-
Method Summary
Modifier and TypeMethodDescriptionackGroupTimeMillis(long ackGroupTimeMillis) Group the consumer acknowledgments for the specified time in milliseconds - defaults to 100.ackGroupTimeMillis(String ackGroupTimeMillis) Group the consumer acknowledgments for the specified time in milliseconds - defaults to 100.ackTimeoutMillis(long ackTimeoutMillis) Timeout for unacknowledged messages in milliseconds - defaults to 10000.ackTimeoutMillis(String ackTimeoutMillis) Timeout for unacknowledged messages in milliseconds - defaults to 10000.ackTimeoutRedeliveryBackoff(String ackTimeoutRedeliveryBackoff) RedeliveryBackoff to use for ack timeout redelivery backoff.ackTimeoutRedeliveryBackoff(org.apache.pulsar.client.api.RedeliveryBackoff ackTimeoutRedeliveryBackoff) RedeliveryBackoff to use for ack timeout redelivery backoff.advanced()allowManualAcknowledgement(boolean allowManualAcknowledgement) Whether to allow manual message acknowledgements.allowManualAcknowledgement(String allowManualAcknowledgement) Whether to allow manual message acknowledgements.authenticationClass(String authenticationClass) The Authentication FQCN to be used while creating the client from URI.authenticationParams(String authenticationParams) The Authentication Parameters to be used while creating the client from URI.consumerName(String consumerName) Name of the consumer when subscription is EXCLUSIVE.consumerNamePrefix(String consumerNamePrefix) Prefix to add to consumer names when a SHARED or FAILOVER subscription is used.consumerQueueSize(int consumerQueueSize) Size of the consumer queue - defaults to 10.consumerQueueSize(String consumerQueueSize) Size of the consumer queue - defaults to 10.deadLetterTopic(String deadLetterTopic) Name of the topic where the messages which fail maxRedeliverCount times will be sent.enableRetry(boolean enableRetry) To enable retry letter topic mode.enableRetry(String enableRetry) To enable retry letter topic mode.keySharedPolicy(String keySharedPolicy) Policy to use by consumer when using key-shared subscription type.maxRedeliverCount(Integer maxRedeliverCount) Maximum number of times that a message will be redelivered before being sent to the dead letter queue.maxRedeliverCount(String maxRedeliverCount) Maximum number of times that a message will be redelivered before being sent to the dead letter queue.messageListener(boolean messageListener) Whether to use the messageListener interface, or to receive messages using a separate thread pool.messageListener(String messageListener) Whether to use the messageListener interface, or to receive messages using a separate thread pool.negativeAckRedeliveryBackoff(String negativeAckRedeliveryBackoff) RedeliveryBackoff to use for negative ack redelivery backoff.negativeAckRedeliveryBackoff(org.apache.pulsar.client.api.RedeliveryBackoff negativeAckRedeliveryBackoff) RedeliveryBackoff to use for negative ack redelivery backoff.negativeAckRedeliveryDelayMicros(long negativeAckRedeliveryDelayMicros) Set the negative acknowledgement delay.negativeAckRedeliveryDelayMicros(String negativeAckRedeliveryDelayMicros) Set the negative acknowledgement delay.numberOfConsumers(int numberOfConsumers) Number of consumers - defaults to 1.numberOfConsumers(String numberOfConsumers) Number of consumers - defaults to 1.numberOfConsumerThreads(int numberOfConsumerThreads) Number of threads to receive and handle messages when using a separate thread pool.numberOfConsumerThreads(String numberOfConsumerThreads) Number of threads to receive and handle messages when using a separate thread pool.readCompacted(boolean readCompacted) Enable compacted topic reading.readCompacted(String readCompacted) Enable compacted topic reading.retryLetterTopic(String retryLetterTopic) Name of the topic to use in retry mode.serviceUrl(String serviceUrl) The Pulsar Service URL to point while creating the client from URI.subscriptionInitialPosition(String subscriptionInitialPosition) Control the initial position in the topic of a newly created subscription.subscriptionInitialPosition(org.apache.camel.component.pulsar.utils.consumers.SubscriptionInitialPosition subscriptionInitialPosition) Control the initial position in the topic of a newly created subscription.subscriptionName(String subscriptionName) Name of the subscription to use.subscriptionTopicsMode(String subscriptionTopicsMode) Determines to which topics this consumer should be subscribed to - Persistent, Non-Persistent, or both.subscriptionTopicsMode(org.apache.pulsar.client.api.RegexSubscriptionMode subscriptionTopicsMode) Determines to which topics this consumer should be subscribed to - Persistent, Non-Persistent, or both.subscriptionType(String subscriptionType) Type of the subscription EXCLUSIVESHAREDFAILOVERKEY_SHARED, defaults to EXCLUSIVE.subscriptionType(org.apache.camel.component.pulsar.utils.consumers.SubscriptionType subscriptionType) Type of the subscription EXCLUSIVESHAREDFAILOVERKEY_SHARED, defaults to EXCLUSIVE.topicsPattern(boolean topicsPattern) Whether the topic is a pattern (regular expression) that allows the consumer to subscribe to all matching topics in the namespace.topicsPattern(String topicsPattern) Whether the topic is a pattern (regular expression) that allows the consumer to subscribe to all matching topics in the namespace.Methods inherited from interface org.apache.camel.builder.EndpointConsumerBuilder
doSetMultiValueProperties, doSetMultiValueProperty, doSetProperty, expr, getRawUri, getUriMethods inherited from interface org.apache.camel.EndpointConsumerResolver
resolve, resolve
-
Method Details
-
advanced
-
authenticationClass
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder authenticationClass(String authenticationClass) The Authentication FQCN to be used while creating the client from URI. The option is a: <code>java.lang.String</code> type. Group: common- Parameters:
authenticationClass- the value to set- Returns:
- the dsl builder
-
authenticationParams
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder authenticationParams(String authenticationParams) The Authentication Parameters to be used while creating the client from URI. The option is a: <code>java.lang.String</code> type. Group: common- Parameters:
authenticationParams- the value to set- Returns:
- the dsl builder
-
serviceUrl
The Pulsar Service URL to point while creating the client from URI. The option is a: <code>java.lang.String</code> type. Group: common- Parameters:
serviceUrl- the value to set- Returns:
- the dsl builder
-
ackGroupTimeMillis
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder ackGroupTimeMillis(long ackGroupTimeMillis) Group the consumer acknowledgments for the specified time in milliseconds - defaults to 100. The option is a: <code>long</code> type. Default: 100 Group: consumer- Parameters:
ackGroupTimeMillis- the value to set- Returns:
- the dsl builder
-
ackGroupTimeMillis
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder ackGroupTimeMillis(String ackGroupTimeMillis) Group the consumer acknowledgments for the specified time in milliseconds - defaults to 100. The option will be converted to a <code>long</code> type. Default: 100 Group: consumer- Parameters:
ackGroupTimeMillis- the value to set- Returns:
- the dsl builder
-
ackTimeoutMillis
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder ackTimeoutMillis(long ackTimeoutMillis) Timeout for unacknowledged messages in milliseconds - defaults to 10000. The option is a: <code>long</code> type. Default: 10000 Group: consumer- Parameters:
ackTimeoutMillis- the value to set- Returns:
- the dsl builder
-
ackTimeoutMillis
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder ackTimeoutMillis(String ackTimeoutMillis) Timeout for unacknowledged messages in milliseconds - defaults to 10000. The option will be converted to a <code>long</code> type. Default: 10000 Group: consumer- Parameters:
ackTimeoutMillis- the value to set- Returns:
- the dsl builder
-
ackTimeoutRedeliveryBackoff
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder ackTimeoutRedeliveryBackoff(org.apache.pulsar.client.api.RedeliveryBackoff ackTimeoutRedeliveryBackoff) RedeliveryBackoff to use for ack timeout redelivery backoff. The option is a: <code>org.apache.pulsar.client.api.RedeliveryBackoff</code> type. Group: consumer- Parameters:
ackTimeoutRedeliveryBackoff- the value to set- Returns:
- the dsl builder
-
ackTimeoutRedeliveryBackoff
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder ackTimeoutRedeliveryBackoff(String ackTimeoutRedeliveryBackoff) RedeliveryBackoff to use for ack timeout redelivery backoff. The option will be converted to a <code>org.apache.pulsar.client.api.RedeliveryBackoff</code> type. Group: consumer- Parameters:
ackTimeoutRedeliveryBackoff- the value to set- Returns:
- the dsl builder
-
allowManualAcknowledgement
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder allowManualAcknowledgement(boolean allowManualAcknowledgement) Whether to allow manual message acknowledgements. If this option is enabled, then messages are not acknowledged automatically after successful route completion. Instead, an instance of PulsarMessageReceipt is stored as a header on the org.apache.camel.Exchange. Messages can then be acknowledged using PulsarMessageReceipt at any time before the ackTimeout occurs. The option is a: <code>boolean</code> type. Default: false Group: consumer- Parameters:
allowManualAcknowledgement- the value to set- Returns:
- the dsl builder
-
allowManualAcknowledgement
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder allowManualAcknowledgement(String allowManualAcknowledgement) Whether to allow manual message acknowledgements. If this option is enabled, then messages are not acknowledged automatically after successful route completion. Instead, an instance of PulsarMessageReceipt is stored as a header on the org.apache.camel.Exchange. Messages can then be acknowledged using PulsarMessageReceipt at any time before the ackTimeout occurs. The option will be converted to a <code>boolean</code> type. Default: false Group: consumer- Parameters:
allowManualAcknowledgement- the value to set- Returns:
- the dsl builder
-
consumerName
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder consumerName(String consumerName) Name of the consumer when subscription is EXCLUSIVE. The option is a: <code>java.lang.String</code> type. Default: sole-consumer Group: consumer- Parameters:
consumerName- the value to set- Returns:
- the dsl builder
-
consumerNamePrefix
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder consumerNamePrefix(String consumerNamePrefix) Prefix to add to consumer names when a SHARED or FAILOVER subscription is used. The option is a: <code>java.lang.String</code> type. Default: cons Group: consumer- Parameters:
consumerNamePrefix- the value to set- Returns:
- the dsl builder
-
consumerQueueSize
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder consumerQueueSize(int consumerQueueSize) Size of the consumer queue - defaults to 10. The option is a: <code>int</code> type. Default: 10 Group: consumer- Parameters:
consumerQueueSize- the value to set- Returns:
- the dsl builder
-
consumerQueueSize
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder consumerQueueSize(String consumerQueueSize) Size of the consumer queue - defaults to 10. The option will be converted to a <code>int</code> type. Default: 10 Group: consumer- Parameters:
consumerQueueSize- the value to set- Returns:
- the dsl builder
-
deadLetterTopic
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder deadLetterTopic(String deadLetterTopic) Name of the topic where the messages which fail maxRedeliverCount times will be sent. Note: if not set, default topic name will be topicName-subscriptionName-DLQ. The option is a: <code>java.lang.String</code> type. Group: consumer- Parameters:
deadLetterTopic- the value to set- Returns:
- the dsl builder
-
enableRetry
To enable retry letter topic mode. The default retry letter topic uses this format: topicname-subscriptionname-RETRY. The option is a: <code>boolean</code> type. Default: false Group: consumer- Parameters:
enableRetry- the value to set- Returns:
- the dsl builder
-
enableRetry
To enable retry letter topic mode. The default retry letter topic uses this format: topicname-subscriptionname-RETRY. The option will be converted to a <code>boolean</code> type. Default: false Group: consumer- Parameters:
enableRetry- the value to set- Returns:
- the dsl builder
-
maxRedeliverCount
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder maxRedeliverCount(Integer maxRedeliverCount) Maximum number of times that a message will be redelivered before being sent to the dead letter queue. If this value is not set, no Dead Letter Policy will be created. The option is a: <code>java.lang.Integer</code> type. Group: consumer- Parameters:
maxRedeliverCount- the value to set- Returns:
- the dsl builder
-
maxRedeliverCount
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder maxRedeliverCount(String maxRedeliverCount) Maximum number of times that a message will be redelivered before being sent to the dead letter queue. If this value is not set, no Dead Letter Policy will be created. The option will be converted to a <code>java.lang.Integer</code> type. Group: consumer- Parameters:
maxRedeliverCount- the value to set- Returns:
- the dsl builder
-
messageListener
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder messageListener(boolean messageListener) Whether to use the messageListener interface, or to receive messages using a separate thread pool. The option is a: <code>boolean</code> type. Default: true Group: consumer- Parameters:
messageListener- the value to set- Returns:
- the dsl builder
-
messageListener
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder messageListener(String messageListener) Whether to use the messageListener interface, or to receive messages using a separate thread pool. The option will be converted to a <code>boolean</code> type. Default: true Group: consumer- Parameters:
messageListener- the value to set- Returns:
- the dsl builder
-
negativeAckRedeliveryBackoff
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder negativeAckRedeliveryBackoff(org.apache.pulsar.client.api.RedeliveryBackoff negativeAckRedeliveryBackoff) RedeliveryBackoff to use for negative ack redelivery backoff. The option is a: <code>org.apache.pulsar.client.api.RedeliveryBackoff</code> type. Group: consumer- Parameters:
negativeAckRedeliveryBackoff- the value to set- Returns:
- the dsl builder
-
negativeAckRedeliveryBackoff
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder negativeAckRedeliveryBackoff(String negativeAckRedeliveryBackoff) RedeliveryBackoff to use for negative ack redelivery backoff. The option will be converted to a <code>org.apache.pulsar.client.api.RedeliveryBackoff</code> type. Group: consumer- Parameters:
negativeAckRedeliveryBackoff- the value to set- Returns:
- the dsl builder
-
negativeAckRedeliveryDelayMicros
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder negativeAckRedeliveryDelayMicros(long negativeAckRedeliveryDelayMicros) Set the negative acknowledgement delay. The option is a: <code>long</code> type. Default: 60000000 Group: consumer- Parameters:
negativeAckRedeliveryDelayMicros- the value to set- Returns:
- the dsl builder
-
negativeAckRedeliveryDelayMicros
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder negativeAckRedeliveryDelayMicros(String negativeAckRedeliveryDelayMicros) Set the negative acknowledgement delay. The option will be converted to a <code>long</code> type. Default: 60000000 Group: consumer- Parameters:
negativeAckRedeliveryDelayMicros- the value to set- Returns:
- the dsl builder
-
numberOfConsumers
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder numberOfConsumers(int numberOfConsumers) Number of consumers - defaults to 1. The option is a: <code>int</code> type. Default: 1 Group: consumer- Parameters:
numberOfConsumers- the value to set- Returns:
- the dsl builder
-
numberOfConsumers
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder numberOfConsumers(String numberOfConsumers) Number of consumers - defaults to 1. The option will be converted to a <code>int</code> type. Default: 1 Group: consumer- Parameters:
numberOfConsumers- the value to set- Returns:
- the dsl builder
-
numberOfConsumerThreads
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder numberOfConsumerThreads(int numberOfConsumerThreads) Number of threads to receive and handle messages when using a separate thread pool. The option is a: <code>int</code> type. Default: 1 Group: consumer- Parameters:
numberOfConsumerThreads- the value to set- Returns:
- the dsl builder
-
numberOfConsumerThreads
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder numberOfConsumerThreads(String numberOfConsumerThreads) Number of threads to receive and handle messages when using a separate thread pool. The option will be converted to a <code>int</code> type. Default: 1 Group: consumer- Parameters:
numberOfConsumerThreads- the value to set- Returns:
- the dsl builder
-
readCompacted
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder readCompacted(boolean readCompacted) Enable compacted topic reading. The option is a: <code>boolean</code> type. Default: false Group: consumer- Parameters:
readCompacted- the value to set- Returns:
- the dsl builder
-
readCompacted
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder readCompacted(String readCompacted) Enable compacted topic reading. The option will be converted to a <code>boolean</code> type. Default: false Group: consumer- Parameters:
readCompacted- the value to set- Returns:
- the dsl builder
-
retryLetterTopic
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder retryLetterTopic(String retryLetterTopic) Name of the topic to use in retry mode. Note: if not set, default topic name will be topicName-subscriptionName-RETRY. The option is a: <code>java.lang.String</code> type. Group: consumer- Parameters:
retryLetterTopic- the value to set- Returns:
- the dsl builder
-
subscriptionInitialPosition
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder subscriptionInitialPosition(org.apache.camel.component.pulsar.utils.consumers.SubscriptionInitialPosition subscriptionInitialPosition) Control the initial position in the topic of a newly created subscription. Default is latest message. The option is a: <code>org.apache.camel.component.pulsar.utils.consumers.SubscriptionInitialPosition</code> type. Default: LATEST Group: consumer- Parameters:
subscriptionInitialPosition- the value to set- Returns:
- the dsl builder
-
subscriptionInitialPosition
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder subscriptionInitialPosition(String subscriptionInitialPosition) Control the initial position in the topic of a newly created subscription. Default is latest message. The option will be converted to a <code>org.apache.camel.component.pulsar.utils.consumers.SubscriptionInitialPosition</code> type. Default: LATEST Group: consumer- Parameters:
subscriptionInitialPosition- the value to set- Returns:
- the dsl builder
-
subscriptionName
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder subscriptionName(String subscriptionName) Name of the subscription to use. The option is a: <code>java.lang.String</code> type. Default: subs Group: consumer- Parameters:
subscriptionName- the value to set- Returns:
- the dsl builder
-
subscriptionTopicsMode
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder subscriptionTopicsMode(org.apache.pulsar.client.api.RegexSubscriptionMode subscriptionTopicsMode) Determines to which topics this consumer should be subscribed to - Persistent, Non-Persistent, or both. Only used with pattern subscriptions. The option is a: <code>org.apache.pulsar.client.api.RegexSubscriptionMode</code> type. Default: PersistentOnly Group: consumer- Parameters:
subscriptionTopicsMode- the value to set- Returns:
- the dsl builder
-
subscriptionTopicsMode
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder subscriptionTopicsMode(String subscriptionTopicsMode) Determines to which topics this consumer should be subscribed to - Persistent, Non-Persistent, or both. Only used with pattern subscriptions. The option will be converted to a <code>org.apache.pulsar.client.api.RegexSubscriptionMode</code> type. Default: PersistentOnly Group: consumer- Parameters:
subscriptionTopicsMode- the value to set- Returns:
- the dsl builder
-
subscriptionType
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder subscriptionType(org.apache.camel.component.pulsar.utils.consumers.SubscriptionType subscriptionType) Type of the subscription EXCLUSIVESHAREDFAILOVERKEY_SHARED, defaults to EXCLUSIVE. The option is a: <code>org.apache.camel.component.pulsar.utils.consumers.SubscriptionType</code> type. Default: EXCLUSIVE Group: consumer- Parameters:
subscriptionType- the value to set- Returns:
- the dsl builder
-
subscriptionType
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder subscriptionType(String subscriptionType) Type of the subscription EXCLUSIVESHAREDFAILOVERKEY_SHARED, defaults to EXCLUSIVE. The option will be converted to a <code>org.apache.camel.component.pulsar.utils.consumers.SubscriptionType</code> type. Default: EXCLUSIVE Group: consumer- Parameters:
subscriptionType- the value to set- Returns:
- the dsl builder
-
topicsPattern
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder topicsPattern(boolean topicsPattern) Whether the topic is a pattern (regular expression) that allows the consumer to subscribe to all matching topics in the namespace. The option is a: <code>boolean</code> type. Default: false Group: consumer- Parameters:
topicsPattern- the value to set- Returns:
- the dsl builder
-
topicsPattern
default PulsarEndpointBuilderFactory.PulsarEndpointConsumerBuilder topicsPattern(String topicsPattern) Whether the topic is a pattern (regular expression) that allows the consumer to subscribe to all matching topics in the namespace. The option will be converted to a <code>boolean</code> type. Default: false Group: consumer- Parameters:
topicsPattern- the value to set- Returns:
- the dsl builder
-