[
https://issues.apache.org/jira/browse/CAMEL-12654?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16552603#comment-16552603
]
Prakhar commented on CAMEL-12654:
---------------------------------
[~dmvolod] Yes, actually I should have mentioned that specifically that this
problem occurs for the custom headers. Proposal for allowNullHeaders looks good.
> RabbitMQ Headers - Headers with null value are skipped.
> -------------------------------------------------------
>
> Key: CAMEL-12654
> URL: https://issues.apache.org/jira/browse/CAMEL-12654
> Project: Camel
> Issue Type: Bug
> Components: camel-rabbitmq
> Affects Versions: 2.21.1
> Reporter: Prakhar
> Priority: Minor
> Labels: headers, rabbitmq
>
> Reference: Conversation with Claus Ibsen on
> [Stackoverflow|https://stackoverflow.com/questions/50583749/apache-camel-how-to-setheader-value-as-null]
> org.apache.camel.component.rabbitmq.RabbitMQMessageConverter.buildProperties()
> skips the headers which have value null. The actual java client for RabbitMQ
> does not have this check. It accepts a basic Map<String,Object> which can
> accept null value.
> [Reference|https://rabbitmq.github.io/rabbitmq-java-client/api/current/com/rabbitmq/client/AMQP.BasicProperties.Builder.html]
> . Check the definition of headers() method
> *The business scenario where we use it*. On the RabbitMQ, we accept messages
> from multiple sources. Depending on whether a specific header is null or not,
> we route these message downstream in our processing pipeline.
> If required, I could provide a working example of rabbitmq java-client to
> demonstrate that the headers with null value are not skipped
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)