It looks like it works with ActiveMQ. But this doesn't mean it will work with WebShereMQ, Oracle Advanced Queuing, ...
What's about adding this.originalInMessage.setAttachments(exchange.getIn().getAttachments()); Could you try this? Best. Christian On Wed, May 2, 2012 at 11:28 AM, Bernard Ligny <bernard.li...@gmail.com>wrote: > I rebuilt the 'camel-core' module with the suggested patch. It is working > fine...but not in *all* situations. > Let me explain: > > a) A *simple* web service request (such a GET with query string) is working > fine. Thanks to the patch, I now see the various headers/properties (like > CamelHttpMethod) of the original message that is put into my DLQ > > b) A more complex web request (such as a POST with an *attachment*) is not > working. The headers are well present, but the multipart attachments are > lost. This makes impossible to "replay" the parked message > > I then tried the following fix (still on 'camel-core' sources) : > > Replace: > this.originalInMessage = new DefaultMessage(); > this.originalInMessage.setBody(exchange.getIn().getBody()); > this.originalInMessage.setHeaders( exchange.getIn().getHeaders() ) > By: > this.originalInMessage = exchange.getIn().copy(); > (NB: exactly what is done for non JMS messages) > > And it is, this time, working in *all* cases, even with attachments > > My problem is finally solved, but I wanted to interrogate Camel specialists > like you in order to be sure that there is no harm/risk of doing a: > this.originalInMessage = exchange.getIn().copy(); > for exchanges of JMS type > > Regards, > > Bernard. > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/OriginalMsg-Why-is-only-the-body-cloned-for-JMS-messages-tp5675413p5680043.html > Sent from the Camel Development mailing list archive at Nabble.com. >