camel-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Joshua Palmer (JIRA)" <j...@apache.org>
Subject [jira] [Created] (CAMEL-6541) DefaultUnitOfWork's headers for the original message are the same object as the in message headers
Date Thu, 11 Jul 2013 16:53:48 GMT
Joshua Palmer created CAMEL-6541:
------------------------------------

             Summary: DefaultUnitOfWork's headers for the original message are the same object
as the in message headers
                 Key: CAMEL-6541
                 URL: https://issues.apache.org/jira/browse/CAMEL-6541
             Project: Camel
          Issue Type: Bug
    Affects Versions: 2.8.6
            Reporter: Joshua Palmer
            Priority: Minor


For jms messages, the useOriginalMessage does not work when headers are changed during the
route because the DefaultUnitOfWork's headers are the same object as the in message's headers.

In DefaultUnitOfWork, this.originalInMessage.setHeaders(exchange.getIn().getHeaders()); should
be changed to create a copy of the headers instead of directly assigning.

Maybe changed to this.originalInMessage.setHeaders((Map<String,Object>) new CaseInsensitiveMap(exchange.getIn().getHeaders()));

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message