You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Vladimir Tsvetkov (JIRA)" <ji...@apache.org> on 2012/06/03 21:30:23 UTC

[jira] [Comment Edited] (CAMEL-5309) Replies with Incorrect CorrelationIDs Received After Reinstantiating a Route with ActiveMQ Endpoint and Exclusive Reply Queue

    [ https://issues.apache.org/jira/browse/CAMEL-5309?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13288242#comment-13288242 ] 

Vladimir Tsvetkov edited comment on CAMEL-5309 at 6/3/12 7:29 PM:
------------------------------------------------------------------

Is .threads(10) makes more sense if the route is:

{code}
from("direct:processStateStart")
.setExchangePattern(ExchangePattern.InOut)
.to("activemq:queue:tasksQueue?replyTo=processedIndecesQueue" +
        "&replyToType=Exclusive" +
        "&requestTimeout=" + PROCESS_INDEX_TIMEOUT)
.threads(10)
.to("log:REPLY?level=DEBUG")
.routeId("route-002")
{code}

As to how I reported the issue, I've tried to provide the minimum information that can describe the issue, and I was waiting to add more (e.g. a unit test) upon request. If you say you need it, I'm willing to invest the time to provide you what you need to ease the troubleshooting.
                
      was (Author: npacemo):
    Is .threads(10) makes more sense if the route is:

{code}
from("direct:processStateStart")
.setExchangePattern(ExchangePattern.InOut)
.to("activemq:queue:tasksQueue?replyTo=processedIndecesQueue" +
        "&replyToType=Exclusive" +
        "&requestTimeout=" + PROCESS_INDEX_TIMEOUT)
.threads(10)
.to("log:REPLY?level=DEBUG")
.routeId("route-002")
{code}

As to how I reported the issue, I've tried to provide the minimum information that can describe the issue, and I was waiting to add more (e.g. a unit test) upon request. 
                  
> Replies with Incorrect CorrelationIDs Received After Reinstantiating a Route with ActiveMQ Endpoint and Exclusive Reply Queue
> -----------------------------------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-5309
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5309
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-activemq, camel-jms
>    Affects Versions: 2.9.2
>         Environment: Java 1.6, ActiveMQ 5.6-SNAPSHOT (used in-memory within a Spring application)
>            Reporter: Vladimir Tsvetkov
>            Assignee: Claus Ibsen
>
> When I first instantiate the following route, it works as expected. The Replies that come have the right correlation ids, just as Camel has assigned them.
> {code}
> from("direct:fetchStateStart")
> .setExchangePattern(ExchangePattern.InOut)
> .to("activemq:queue:tasksQueue?replyTo=completionsQueue" +
>         "&replyToType=Exclusive" +
>         "&requestTimeout=" + FETCH_INDEX_TIMEOUT)
> .threads(10)
> .routeId("route-001");
> {code}
> When this route completes, it is stopped and removed from the camel context. 
> When a similar route is instantiated:
> {code}
> from("direct:processStateStart")
> .setExchangePattern(ExchangePattern.InOut)
> .to("activemq:queue:tasksQueue?replyTo=completionsQueue" +
>         "&replyToType=Exclusive" +
>         "&requestTimeout=" + PROCESS_INDEX_TIMEOUT)
> .threads(10)
> .routeId("route-002");
> {code}
> Half of the replies come as expected, while the other half results in the following warning: *Reply received for unknown correlationID*.
> A workaround for this issues is to use a different *ReplyTo*-queue for each new instantiation of a similar route.
> E.g. for the second route, it'll work if:
> {code}
> from("direct:processStateStart")
> .setExchangePattern(ExchangePattern.InOut)
> .to("activemq:queue:tasksQueue?replyTo=processedIndecesQueue" +
>         "&replyToType=Exclusive" +
>         "&requestTimeout=" + PROCESS_INDEX_TIMEOUT)
> .threads(10)
> .routeId("route-002");
> {code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira