Answer a question

I am trying to set the delivery.timeout.ms property on the Producer Configuration however I can't find any suitable (Camel Component) Option under the Camel Kafka component doc page.

I was expecting to see a deliveryTimeoutMs option to be available (just like the requestTimeoutMs is to request.timeout.ms) but it just isn't there.

According to the camel-kafka api page there's no method available, across all versions, so is this option just not supported via Camel?

Answers

The Producer configuration delivery.timeout.ms has been added to the KafkaProducer configurations only in recent versions of Kafka. As I understand the documentation on Kafka Camel Options you would then need to add the prefix "additionalProperties" at the beginning, like this:

additionalProperties.delivery.timeout.ms

When changing the delivery timeout make sure to follow the recommendation: "The value of this config should be greater than or equal to the sum of request.timeout.ms and linger.ms."

The exakt description on Kafka Camel Options is

"Sets additional properties for either kafka consumer or kafka producer in case they can’t be set directly on the camel configurations (e.g: new Kafka properties that are not reflected yet in Camel configurations), the properties have to be prefixed with additionalProperties."

Logo

华为、百度、京东云现已入驻,来创建你的专属开发者社区吧!

更多推荐