Now it works. I'll send the patch asap.
Guillaume Nodet (JIRA) ha scritto:
[ https://issues.apache.org/activemq/browse/SM-751?page=comments#action_37521 ] Guillaume Nodet commented on SM-751:------------------------------------ You need to clean the thread local. In the processExchange method, just do: protected void processExchange(MessageExchange exchange) throws Exception { try { corrId.set(exchange.getProperty("correlationId")); ... put the current code here ... } finally { corrId.set(null); } } This way you should not experience the problem you explained.Flow tracing with correlation id -------------------------------- Key: SM-751 URL: https://issues.apache.org/activemq/browse/SM-751 Project: ServiceMix Issue Type: Improvement Reporter: Gianfranco Boccalon Attachments: servicemix-components.zip Add the possibility to trace the flow of the messages inside a Service Assembly. For example, if we have a Service Assembly composed of three components, two binding components (call them BC1 and BC2) and a service engine (SE) organized in this sequence BC1->SE->BC2, we need to recognize that the output messages produced by the SE component are related to some messages provided by BC1. To do this, we need to add a "process correlation id" to the message exchanges and to modify the used components, to propagate this correlation id in all Message Exchanges sent. Enclosed there is the modified code for the following components: - HTTP binding component: here I added the code to generate the correlation Id and set it in the Message Exchange - Splitter- Router (the lightweight component)
