camel-spring-rabbitmq-kafka-connector source configuration

Connector Description: Send and receive messages from RabbitMQ using Spring RabbitMQ client.

When using camel-spring-rabbitmq-kafka-connector as source make sure to use the following Maven dependency to have support for the connector:

<dependency>
  <groupId>org.apache.camel.kafkaconnector</groupId>
  <artifactId>camel-spring-rabbitmq-kafka-connector</artifactId>
  <version>x.x.x</version>
  <!-- use the same version as your Camel Kafka connector version -->
</dependency>

To use this source connector in Kafka connect you’ll need to set the following connector.class

connector.class=org.apache.camel.kafkaconnector.springrabbitmq.CamelSpringrabbitmqSourceConnector

The camel-spring-rabbitmq source connector supports 58 options, which are listed below.

Name Description Default Priority

camel.source.path.exchangeName

Required The exchange name determines the exchange to which the produced messages will be sent to. In the case of consumers, the exchange name determines the exchange the queue will be bound to. Note: to use default exchange then do not use empty name, but use default instead.

HIGH

camel.source.endpoint.connectionFactory

The connection factory to be use. A connection factory must be configured either on the component or endpoint.

MEDIUM

camel.source.endpoint.disableReplyTo

Specifies whether Camel ignores the ReplyTo header in messages. If true, Camel does not send a reply back to the destination specified in the ReplyTo header. You can use this option if you want Camel to consume from a route and you do not want Camel to automatically send back a reply message because another component in your code handles the reply message. You can also use this option if you want to use Camel as a proxy between different message brokers and you want to route message from one system to another.

false

MEDIUM

camel.source.endpoint.routingKey

The value of a routing key to use. Default is empty which is not helpful when using the default (or any direct) exchange, but fine if the exchange is a headers exchange for instance.

MEDIUM

camel.source.endpoint.testConnectionOnStartup

Specifies whether to test the connection on startup. This ensures that when Camel starts that all the JMS consumers have a valid connection to the JMS broker. If a connection cannot be granted then Camel throws an exception on startup. This ensures that Camel is not started with failed connections. The JMS producers is tested as well.

false

MEDIUM

camel.source.endpoint.acknowledgeMode

Flag controlling the behaviour of the container with respect to message acknowledgement. The most common usage is to let the container handle the acknowledgements (so the listener doesn’t need to know about the channel or the message). Set to AcknowledgeMode.MANUAL if the listener will send the acknowledgements itself using Channel.basicAck(long, boolean). Manual acks are consistent with either a transactional or non-transactional channel, but if you are doing no other work on the channel at the same other than receiving a single message then the transaction is probably unnecessary. Set to AcknowledgeMode.NONE to tell the broker not to expect any acknowledgements, and it will assume all messages are acknowledged as soon as they are sent (this is autoack in native Rabbit broker terms). If AcknowledgeMode.NONE then the channel cannot be transactional (so the container will fail on start up if that flag is accidentally set). One of: [NONE] [MANUAL] [AUTO].

Enum values:

  • NONE

  • MANUAL

  • AUTO

MEDIUM

camel.source.endpoint.asyncConsumer

Whether the consumer processes the Exchange asynchronously. If enabled then the consumer may pickup the next message from the queue, while the previous message is being processed asynchronously (by the Asynchronous Routing Engine). This means that messages may be processed not 100% strictly in order. If disabled (as default) then the Exchange is fully processed before the consumer will pickup the next message from the queue.

false

MEDIUM

camel.source.endpoint.autoDeclare

Specifies whether the consumer should auto declare binding between exchange, queue and routing key when starting.

true

MEDIUM

camel.source.endpoint.autoStartup

Specifies whether the consumer container should auto-startup.

true

MEDIUM

camel.source.endpoint.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.

false

MEDIUM

camel.source.endpoint.deadLetterExchange

The name of the dead letter exchange.

MEDIUM

camel.source.endpoint.deadLetterExchangeType

The type of the dead letter exchange One of: [direct] [fanout] [headers] [topic].

Enum values:

  • direct

  • fanout

  • headers

  • topic

"direct"

MEDIUM

camel.source.endpoint.deadLetterQueue

The name of the dead letter queue.

MEDIUM

camel.source.endpoint.deadLetterRoutingKey

The routing key for the dead letter exchange.

MEDIUM

camel.source.endpoint.exchangeType

The type of the exchange One of: [direct] [fanout] [headers] [topic].

Enum values:

  • direct

  • fanout

  • headers

  • topic

"direct"

MEDIUM

camel.source.endpoint.exclusive

Set to true for an exclusive consumer.

false

MEDIUM

camel.source.endpoint.maximumRetryAttempts

How many times a Rabbitmq consumer will retry the same message if Camel failed to process the message.

5

MEDIUM

camel.source.endpoint.noLocal

Set to true for an no-local consumer.

false

MEDIUM

camel.source.endpoint.queues

The queue(s) to use for consuming messages. Multiple queue names can be separated by comma. If none has been configured then Camel will generate an unique id as the queue name for the consumer.

MEDIUM

camel.source.endpoint.rejectAndDontRequeue

Whether a Rabbitmq consumer should reject the message without requeuing. This enables failed messages to be sent to a Dead Letter Exchange/Queue, if the broker is so configured.

true

MEDIUM

camel.source.endpoint.retryDelay

Delay in msec a Rabbitmq consumer will wait before redelivering a message that Camel failed to process.

1000

MEDIUM

camel.source.endpoint.concurrentConsumers

The number of consumers.

MEDIUM

camel.source.endpoint.exceptionHandler

To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with exceptions, that will be logged at WARN or ERROR level and ignored.

MEDIUM

camel.source.endpoint.exchangePattern

Sets the exchange pattern when the consumer creates an exchange. One of: [InOnly] [InOut] [InOptionalOut].

Enum values:

  • InOnly

  • InOut

  • InOptionalOut

MEDIUM

camel.source.endpoint.maxConcurrentConsumers

The maximum number of consumers (available only with SMLC).

MEDIUM

camel.source.endpoint.messageListenerContainerType

The type of the MessageListenerContainer One of: [DMLC] [SMLC].

Enum values:

  • DMLC

  • SMLC

"DMLC"

MEDIUM

camel.source.endpoint.prefetchCount

Tell the broker how many messages to send in a single request. Often this can be set quite high to improve throughput.

MEDIUM

camel.source.endpoint.retry

Custom retry configuration to use. If this is configured then the other settings such as maximumRetryAttempts for retry are not in use.

MEDIUM

camel.source.endpoint.args

Specify arguments for configuring the different RabbitMQ concepts, a different prefix is required for each element: arg.consumer. arg.exchange. arg.queue. arg.binding. arg.dlq.exchange. arg.dlq.queue. arg.dlq.binding. For example to declare a queue with message ttl argument: args=arg.queue.x-message-ttl=60000.

MEDIUM

camel.source.endpoint.messageConverter

To use a custom MessageConverter so you can be in control how to map to/from a org.springframework.amqp.core.Message.

MEDIUM

camel.source.endpoint.messagePropertiesConverter

To use a custom MessagePropertiesConverter so you can be in control how to map to/from a org.springframework.amqp.core.MessageProperties.

MEDIUM

camel.source.endpoint.synchronous

Sets whether synchronous processing should be strictly used.

false

MEDIUM

camel.component.spring-rabbitmq.amqpAdmin

Optional AMQP Admin service to use for auto declaring elements (queues, exchanges, bindings).

MEDIUM

camel.component.spring-rabbitmq.connectionFactory

The connection factory to be use. A connection factory must be configured either on the component or endpoint.

MEDIUM

camel.component.spring-rabbitmq.testConnectionOnStartup

Specifies whether to test the connection on startup. This ensures that when Camel starts that all the JMS consumers have a valid connection to the JMS broker. If a connection cannot be granted then Camel throws an exception on startup. This ensures that Camel is not started with failed connections. The JMS producers is tested as well.

false

MEDIUM

camel.component.spring-rabbitmq.autoDeclare

Specifies whether the consumer should auto declare binding between exchange, queue and routing key when starting. Enabling this can be good for development to make it easy to standup exchanges, queues and bindings on the broker.

false

MEDIUM

camel.component.spring-rabbitmq.autoStartup

Specifies whether the consumer container should auto-startup.

true

MEDIUM

camel.component.spring-rabbitmq.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.

false

MEDIUM

camel.component.spring-rabbitmq.deadLetterExchange

The name of the dead letter exchange.

MEDIUM

camel.component.spring-rabbitmq.deadLetterExchangeType

The type of the dead letter exchange One of: [direct] [fanout] [headers] [topic].

Enum values:

  • direct

  • fanout

  • headers

  • topic

"direct"

MEDIUM

camel.component.spring-rabbitmq.deadLetterQueue

The name of the dead letter queue.

MEDIUM

camel.component.spring-rabbitmq.deadLetterRoutingKey

The routing key for the dead letter exchange.

MEDIUM

camel.component.spring-rabbitmq.maximumRetryAttempts

How many times a Rabbitmq consumer will retry the same message if Camel failed to process the message.

5

MEDIUM

camel.component.spring-rabbitmq.rejectAndDontRequeue

Whether a Rabbitmq consumer should reject the message without requeuing. This enables failed messages to be sent to a Dead Letter Exchange/Queue, if the broker is so configured.

true

MEDIUM

camel.component.spring-rabbitmq.retryDelay

Delay in msec a Rabbitmq consumer will wait before redelivering a message that Camel failed to process.

1000

MEDIUM

camel.component.spring-rabbitmq.concurrentConsumers

The number of consumers.

1

MEDIUM

camel.component.spring-rabbitmq.errorHandler

To use a custom ErrorHandler for handling exceptions from the message listener (consumer).

MEDIUM

camel.component.spring-rabbitmq.listenerContainerFactory

To use a custom factory for creating and configuring ListenerContainer to be used by the consumer for receiving messages.

MEDIUM

camel.component.spring-rabbitmq.maxConcurrentConsumers

The maximum number of consumers (available only with SMLC).

MEDIUM

camel.component.spring-rabbitmq.messageListenerContainerType

The type of the MessageListenerContainer One of: [DMLC] [SMLC].

Enum values:

  • DMLC

  • SMLC

"DMLC"

MEDIUM

camel.component.spring-rabbitmq.prefetchCount

Tell the broker how many messages to send to each consumer in a single request. Often this can be set quite high to improve throughput.

250

MEDIUM

camel.component.spring-rabbitmq.retry

Custom retry configuration to use. If this is configured then the other settings such as maximumRetryAttempts for retry are not in use.

MEDIUM

camel.component.spring-rabbitmq.shutdownTimeout

The time to wait for workers in milliseconds after the container is stopped. If any workers are active when the shutdown signal comes they will be allowed to finish processing as long as they can finish within this timeout.

5000L

MEDIUM

camel.component.spring-rabbitmq.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.

true

MEDIUM

camel.component.spring-rabbitmq.ignoreDeclarationExceptions

Switch on ignore exceptions such as mismatched properties when declaring.

false

MEDIUM

camel.component.spring-rabbitmq.messageConverter

To use a custom MessageConverter so you can be in control how to map to/from a org.springframework.amqp.core.Message.

MEDIUM

camel.component.spring-rabbitmq.messagePropertiesConverter

To use a custom MessagePropertiesConverter so you can be in control how to map to/from a org.springframework.amqp.core.MessageProperties.

MEDIUM

camel.component.spring-rabbitmq.headerFilterStrategy

To use a custom org.apache.camel.spi.HeaderFilterStrategy to filter header to and from Camel message.

MEDIUM

The camel-spring-rabbitmq source connector has no converters out of the box.

The camel-spring-rabbitmq source connector has no transforms out of the box.

The camel-spring-rabbitmq source connector has no aggregation strategies out of the box.