You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Christopher Barrow (Created) (JIRA)" <ji...@apache.org> on 2011/10/13 23:43:12 UTC

[jira] [Created] (AMQ-3543) STOMP connector: unexpected reply-to value for remote temporary topic

STOMP connector: unexpected reply-to value for remote temporary topic
---------------------------------------------------------------------

                 Key: AMQ-3543
                 URL: https://issues.apache.org/jira/browse/AMQ-3543
             Project: ActiveMQ
          Issue Type: Bug
            Reporter: Christopher Barrow
            Priority: Minor


The reply-to header on a MESSAGE frame resulting from the sending of a message (SEND) with the reply-to header set to a temporary topic is in the form /temp-topic/<local-temp-topic-name> rather than the expected 
/remote-temp-topic/<system_generated_name>

This only happens when the same connection is used for sending and receiving messages. When a temporary queue is used, the reply-two appears as /remote-temp-queue/xxx as expected. So even if one takes the position that it is reasonable for the local name to be used given that everything is on the same connection, there is an inconsistency between the topic and queue cases. For our purposes we would prefer that the remote form be used always.

Test case for the underlying ActiveMQ bug is attached: StompRemoteTempTopic.java

To reproduce, drop this file into $ACTIVEMQ_HOME/example/src, edit build.xml in the example
directory to add the following:

<target name="bug" depends="compile" description="Runs test case for replyTo TempTopic bug">
<echo>Running a Stomp example</echo>
<java classname="StompRemoteTempTopic" fork="yes" maxmemory="100M">
<classpath refid="javac.classpath" />
<jvmarg value="-server" />
</java>
</target>

and run by issuing the command "ant bug". Output is as follows:

[echo] Running a Stomp example
[java] =====================================================
[java] Test run using temporary topic
[java] -----------------------------------------------------
[java] Sending request message: SEND with reply-to=/temp-topic/2C26441740C0ECC9tt1
[java] Received request message: MESSAGE with reply-to=/temp-topic/2C26441740C0ECC9tt1
[java] Response MESSAGE received
[java] =====================================================
[java] Test run using temporary queue
[java] -----------------------------------------------------
[java] Sending request message: SEND with reply-to=/temp-queue/2C26441740C0ECC9tt1
[java] Received request message: MESSAGE with reply-to=/remote-temp-queue/ID:ChrisBarrow-lap-61815-1318539910206-4:6:1
[java] Response MESSAGE received

This makes it easy to see that for the queue case the reply-to is set to the remote temporary queue but for the topic case the local temporary topic is specified.


--
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

        

[jira] [Resolved] (AMQ-3543) STOMP connector: unexpected reply-to value for remote temporary topic

Posted by "Timothy Bish (Resolved) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/AMQ-3543?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Timothy Bish resolved AMQ-3543.
-------------------------------

    Resolution: Fixed

Fix applied in trunk, the reply-to destinations will be set to the same as what was given in the original message.  The remote names shouldn't leak from the Stomp transport.  Test case added.
                
> STOMP connector: unexpected reply-to value for remote temporary topic
> ---------------------------------------------------------------------
>
>                 Key: AMQ-3543
>                 URL: https://issues.apache.org/jira/browse/AMQ-3543
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: stomp
>    Affects Versions: 5.x
>            Reporter: Christopher Barrow
>            Assignee: Timothy Bish
>            Priority: Minor
>             Fix For: 5.6.0
>
>         Attachments: StompRemoteTempTopic.java
>
>
> The reply-to header on a MESSAGE frame resulting from the sending of a message (SEND) with the reply-to header set to a temporary topic is in the form /temp-topic/<local-temp-topic-name> rather than the expected 
> /remote-temp-topic/<system_generated_name>
> This only happens when the same connection is used for sending and receiving messages. When a temporary queue is used, the reply-to appears as /remote-temp-queue/xxx as expected. So even if one takes the position that it is reasonable for the local name to be used given that everything is on the same connection, there is an inconsistency between the topic and queue cases. For our purposes we would prefer that the remote form be used always, because we are actually servicing two different users on the same connection (first user does the SEND, second user receives the MESSAGE).
> Test case for the underlying ActiveMQ bug is attached: StompRemoteTempTopic.java
> To reproduce, drop this file into $ACTIVEMQ_HOME/example/src, edit build.xml in the example
> directory to add the following:
> <target name="bug" depends="compile" description="Runs test case for replyTo TempTopic bug">
> <echo>Running a Stomp example</echo>
> <java classname="StompRemoteTempTopic" fork="yes" maxmemory="100M">
> <classpath refid="javac.classpath" />
> <jvmarg value="-server" />
> </java>
> </target>
> and run by issuing the command "ant bug". Output is as follows:
> [echo] Running a Stomp example
> [java] =====================================================
> [java] Test run using temporary topic
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Response MESSAGE received
> [java] =====================================================
> [java] Test run using temporary queue
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-queue/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/remote-temp-queue/ID:ChrisBarrow-lap-61815-1318539910206-4:6:1
> [java] Response MESSAGE received
> This makes it easy to see that for the queue case the reply-to is set to the remote temporary queue but for the topic case the local temporary topic is specified.

--
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

        

[jira] [Commented] (AMQ-3543) STOMP connector: unexpected reply-to value for remote temporary topic

Posted by "Christopher Barrow (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/AMQ-3543?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13127876#comment-13127876 ] 

Christopher Barrow commented on AMQ-3543:
-----------------------------------------

Wow, thanks for such a quick response! Just want to check my understanding of your fix. Does it mean the received MESSAGE with reply-to ( received as a result of the SEND) will now have reply-to = '/temp-queue/...' or '/temp-topic/...'? 

What about the case where two connections are used (one connection owns the temporary destination and emits the SEND with reply-to, a second connection receives the MESSAGE). Presumably in that case the reply-to would have to be '/remote-temp-queue/...' or '/remote-temp-topic/...' since the queue actually belongs to the other connection?
                
> STOMP connector: unexpected reply-to value for remote temporary topic
> ---------------------------------------------------------------------
>
>                 Key: AMQ-3543
>                 URL: https://issues.apache.org/jira/browse/AMQ-3543
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: stomp
>    Affects Versions: 5.x
>            Reporter: Christopher Barrow
>            Assignee: Timothy Bish
>            Priority: Minor
>             Fix For: 5.6.0
>
>         Attachments: StompRemoteTempTopic.java
>
>
> The reply-to header on a MESSAGE frame resulting from the sending of a message (SEND) with the reply-to header set to a temporary topic is in the form /temp-topic/<local-temp-topic-name> rather than the expected 
> /remote-temp-topic/<system_generated_name>
> This only happens when the same connection is used for sending and receiving messages. When a temporary queue is used, the reply-to appears as /remote-temp-queue/xxx as expected. So even if one takes the position that it is reasonable for the local name to be used given that everything is on the same connection, there is an inconsistency between the topic and queue cases. For our purposes we would prefer that the remote form be used always, because we are actually servicing two different users on the same connection (first user does the SEND, second user receives the MESSAGE).
> Test case for the underlying ActiveMQ bug is attached: StompRemoteTempTopic.java
> To reproduce, drop this file into $ACTIVEMQ_HOME/example/src, edit build.xml in the example
> directory to add the following:
> <target name="bug" depends="compile" description="Runs test case for replyTo TempTopic bug">
> <echo>Running a Stomp example</echo>
> <java classname="StompRemoteTempTopic" fork="yes" maxmemory="100M">
> <classpath refid="javac.classpath" />
> <jvmarg value="-server" />
> </java>
> </target>
> and run by issuing the command "ant bug". Output is as follows:
> [echo] Running a Stomp example
> [java] =====================================================
> [java] Test run using temporary topic
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Response MESSAGE received
> [java] =====================================================
> [java] Test run using temporary queue
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-queue/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/remote-temp-queue/ID:ChrisBarrow-lap-61815-1318539910206-4:6:1
> [java] Response MESSAGE received
> This makes it easy to see that for the queue case the reply-to is set to the remote temporary queue but for the topic case the local temporary topic is specified.

--
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

        

[jira] [Updated] (AMQ-3543) STOMP connector: unexpected reply-to value for remote temporary topic

Posted by "Timothy Bish (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/AMQ-3543?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Timothy Bish updated AMQ-3543:
------------------------------

          Component/s: stomp
    Affects Version/s: 5.x
        Fix Version/s: 5.6.0
             Assignee: Timothy Bish
    
> STOMP connector: unexpected reply-to value for remote temporary topic
> ---------------------------------------------------------------------
>
>                 Key: AMQ-3543
>                 URL: https://issues.apache.org/jira/browse/AMQ-3543
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: stomp
>    Affects Versions: 5.x
>            Reporter: Christopher Barrow
>            Assignee: Timothy Bish
>            Priority: Minor
>             Fix For: 5.6.0
>
>         Attachments: StompRemoteTempTopic.java
>
>
> The reply-to header on a MESSAGE frame resulting from the sending of a message (SEND) with the reply-to header set to a temporary topic is in the form /temp-topic/<local-temp-topic-name> rather than the expected 
> /remote-temp-topic/<system_generated_name>
> This only happens when the same connection is used for sending and receiving messages. When a temporary queue is used, the reply-to appears as /remote-temp-queue/xxx as expected. So even if one takes the position that it is reasonable for the local name to be used given that everything is on the same connection, there is an inconsistency between the topic and queue cases. For our purposes we would prefer that the remote form be used always, because we are actually servicing two different users on the same connection (first user does the SEND, second user receives the MESSAGE).
> Test case for the underlying ActiveMQ bug is attached: StompRemoteTempTopic.java
> To reproduce, drop this file into $ACTIVEMQ_HOME/example/src, edit build.xml in the example
> directory to add the following:
> <target name="bug" depends="compile" description="Runs test case for replyTo TempTopic bug">
> <echo>Running a Stomp example</echo>
> <java classname="StompRemoteTempTopic" fork="yes" maxmemory="100M">
> <classpath refid="javac.classpath" />
> <jvmarg value="-server" />
> </java>
> </target>
> and run by issuing the command "ant bug". Output is as follows:
> [echo] Running a Stomp example
> [java] =====================================================
> [java] Test run using temporary topic
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Response MESSAGE received
> [java] =====================================================
> [java] Test run using temporary queue
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-queue/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/remote-temp-queue/ID:ChrisBarrow-lap-61815-1318539910206-4:6:1
> [java] Response MESSAGE received
> This makes it easy to see that for the queue case the reply-to is set to the remote temporary queue but for the topic case the local temporary topic is specified.

--
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

        

[jira] [Updated] (AMQ-3543) STOMP connector: unexpected reply-to value for remote temporary topic

Posted by "Christopher Barrow (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/AMQ-3543?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christopher Barrow updated AMQ-3543:
------------------------------------

    Description: 
The reply-to header on a MESSAGE frame resulting from the sending of a message (SEND) with the reply-to header set to a temporary topic is in the form /temp-topic/<local-temp-topic-name> rather than the expected 
/remote-temp-topic/<system_generated_name>

This only happens when the same connection is used for sending and receiving messages. When a temporary queue is used, the reply-to appears as /remote-temp-queue/xxx as expected. So even if one takes the position that it is reasonable for the local name to be used given that everything is on the same connection, there is an inconsistency between the topic and queue cases. For our purposes we would prefer that the remote form be used always, because we are actually servicing two different users on the same connection (first user does the SEND, second user receives the MESSAGE).

Test case for the underlying ActiveMQ bug is attached: StompRemoteTempTopic.java

To reproduce, drop this file into $ACTIVEMQ_HOME/example/src, edit build.xml in the example
directory to add the following:

<target name="bug" depends="compile" description="Runs test case for replyTo TempTopic bug">
<echo>Running a Stomp example</echo>
<java classname="StompRemoteTempTopic" fork="yes" maxmemory="100M">
<classpath refid="javac.classpath" />
<jvmarg value="-server" />
</java>
</target>

and run by issuing the command "ant bug". Output is as follows:

[echo] Running a Stomp example
[java] =====================================================
[java] Test run using temporary topic
[java] -----------------------------------------------------
[java] Sending request message: SEND with reply-to=/temp-topic/2C26441740C0ECC9tt1
[java] Received request message: MESSAGE with reply-to=/temp-topic/2C26441740C0ECC9tt1
[java] Response MESSAGE received
[java] =====================================================
[java] Test run using temporary queue
[java] -----------------------------------------------------
[java] Sending request message: SEND with reply-to=/temp-queue/2C26441740C0ECC9tt1
[java] Received request message: MESSAGE with reply-to=/remote-temp-queue/ID:ChrisBarrow-lap-61815-1318539910206-4:6:1
[java] Response MESSAGE received

This makes it easy to see that for the queue case the reply-to is set to the remote temporary queue but for the topic case the local temporary topic is specified.


  was:
The reply-to header on a MESSAGE frame resulting from the sending of a message (SEND) with the reply-to header set to a temporary topic is in the form /temp-topic/<local-temp-topic-name> rather than the expected 
/remote-temp-topic/<system_generated_name>

This only happens when the same connection is used for sending and receiving messages. When a temporary queue is used, the reply-two appears as /remote-temp-queue/xxx as expected. So even if one takes the position that it is reasonable for the local name to be used given that everything is on the same connection, there is an inconsistency between the topic and queue cases. For our purposes we would prefer that the remote form be used always.

Test case for the underlying ActiveMQ bug is attached: StompRemoteTempTopic.java

To reproduce, drop this file into $ACTIVEMQ_HOME/example/src, edit build.xml in the example
directory to add the following:

<target name="bug" depends="compile" description="Runs test case for replyTo TempTopic bug">
<echo>Running a Stomp example</echo>
<java classname="StompRemoteTempTopic" fork="yes" maxmemory="100M">
<classpath refid="javac.classpath" />
<jvmarg value="-server" />
</java>
</target>

and run by issuing the command "ant bug". Output is as follows:

[echo] Running a Stomp example
[java] =====================================================
[java] Test run using temporary topic
[java] -----------------------------------------------------
[java] Sending request message: SEND with reply-to=/temp-topic/2C26441740C0ECC9tt1
[java] Received request message: MESSAGE with reply-to=/temp-topic/2C26441740C0ECC9tt1
[java] Response MESSAGE received
[java] =====================================================
[java] Test run using temporary queue
[java] -----------------------------------------------------
[java] Sending request message: SEND with reply-to=/temp-queue/2C26441740C0ECC9tt1
[java] Received request message: MESSAGE with reply-to=/remote-temp-queue/ID:ChrisBarrow-lap-61815-1318539910206-4:6:1
[java] Response MESSAGE received

This makes it easy to see that for the queue case the reply-to is set to the remote temporary queue but for the topic case the local temporary topic is specified.


    
> STOMP connector: unexpected reply-to value for remote temporary topic
> ---------------------------------------------------------------------
>
>                 Key: AMQ-3543
>                 URL: https://issues.apache.org/jira/browse/AMQ-3543
>             Project: ActiveMQ
>          Issue Type: Bug
>            Reporter: Christopher Barrow
>            Priority: Minor
>         Attachments: StompRemoteTempTopic.java
>
>
> The reply-to header on a MESSAGE frame resulting from the sending of a message (SEND) with the reply-to header set to a temporary topic is in the form /temp-topic/<local-temp-topic-name> rather than the expected 
> /remote-temp-topic/<system_generated_name>
> This only happens when the same connection is used for sending and receiving messages. When a temporary queue is used, the reply-to appears as /remote-temp-queue/xxx as expected. So even if one takes the position that it is reasonable for the local name to be used given that everything is on the same connection, there is an inconsistency between the topic and queue cases. For our purposes we would prefer that the remote form be used always, because we are actually servicing two different users on the same connection (first user does the SEND, second user receives the MESSAGE).
> Test case for the underlying ActiveMQ bug is attached: StompRemoteTempTopic.java
> To reproduce, drop this file into $ACTIVEMQ_HOME/example/src, edit build.xml in the example
> directory to add the following:
> <target name="bug" depends="compile" description="Runs test case for replyTo TempTopic bug">
> <echo>Running a Stomp example</echo>
> <java classname="StompRemoteTempTopic" fork="yes" maxmemory="100M">
> <classpath refid="javac.classpath" />
> <jvmarg value="-server" />
> </java>
> </target>
> and run by issuing the command "ant bug". Output is as follows:
> [echo] Running a Stomp example
> [java] =====================================================
> [java] Test run using temporary topic
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Response MESSAGE received
> [java] =====================================================
> [java] Test run using temporary queue
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-queue/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/remote-temp-queue/ID:ChrisBarrow-lap-61815-1318539910206-4:6:1
> [java] Response MESSAGE received
> This makes it easy to see that for the queue case the reply-to is set to the remote temporary queue but for the topic case the local temporary topic is specified.

--
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

        

[jira] [Commented] (AMQ-3543) STOMP connector: unexpected reply-to value for remote temporary topic

Posted by "Timothy Bish (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/AMQ-3543?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13127892#comment-13127892 ] 

Timothy Bish commented on AMQ-3543:
-----------------------------------

>From the client side the replyTo destination's parent connection should be opaque, so all connections would receive the same /temp-topic/ or /temp-queue/ values.  Its up to your clients to ensure that the name's of the temp destinations that they create are unique, using a UUID for instance.  The remote prefix is used internally by amq to match up its own destination structures and shouldn't have been leaking out of the Stomp transport.  
                
> STOMP connector: unexpected reply-to value for remote temporary topic
> ---------------------------------------------------------------------
>
>                 Key: AMQ-3543
>                 URL: https://issues.apache.org/jira/browse/AMQ-3543
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: stomp
>    Affects Versions: 5.x
>            Reporter: Christopher Barrow
>            Assignee: Timothy Bish
>            Priority: Minor
>             Fix For: 5.6.0
>
>         Attachments: StompRemoteTempTopic.java
>
>
> The reply-to header on a MESSAGE frame resulting from the sending of a message (SEND) with the reply-to header set to a temporary topic is in the form /temp-topic/<local-temp-topic-name> rather than the expected 
> /remote-temp-topic/<system_generated_name>
> This only happens when the same connection is used for sending and receiving messages. When a temporary queue is used, the reply-to appears as /remote-temp-queue/xxx as expected. So even if one takes the position that it is reasonable for the local name to be used given that everything is on the same connection, there is an inconsistency between the topic and queue cases. For our purposes we would prefer that the remote form be used always, because we are actually servicing two different users on the same connection (first user does the SEND, second user receives the MESSAGE).
> Test case for the underlying ActiveMQ bug is attached: StompRemoteTempTopic.java
> To reproduce, drop this file into $ACTIVEMQ_HOME/example/src, edit build.xml in the example
> directory to add the following:
> <target name="bug" depends="compile" description="Runs test case for replyTo TempTopic bug">
> <echo>Running a Stomp example</echo>
> <java classname="StompRemoteTempTopic" fork="yes" maxmemory="100M">
> <classpath refid="javac.classpath" />
> <jvmarg value="-server" />
> </java>
> </target>
> and run by issuing the command "ant bug". Output is as follows:
> [echo] Running a Stomp example
> [java] =====================================================
> [java] Test run using temporary topic
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Response MESSAGE received
> [java] =====================================================
> [java] Test run using temporary queue
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-queue/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/remote-temp-queue/ID:ChrisBarrow-lap-61815-1318539910206-4:6:1
> [java] Response MESSAGE received
> This makes it easy to see that for the queue case the reply-to is set to the remote temporary queue but for the topic case the local temporary topic is specified.

--
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

        

[jira] [Issue Comment Edited] (AMQ-3543) STOMP connector: unexpected reply-to value for remote temporary topic

Posted by "Christopher Barrow (Issue Comment Edited) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/AMQ-3543?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13127876#comment-13127876 ] 

Christopher Barrow edited comment on AMQ-3543 at 10/14/11 9:35 PM:
-------------------------------------------------------------------

Wow, thanks for such a quick response! Just want to check my understanding of your fix. Does it mean the received MESSAGE with reply-to ( received as a result of the SEND) will now have reply-to = '/temp-queue/...' or '/temp-topic/...'? 

What about the case where two connections are used (one connection owns the temporary destination and emits the SEND with reply-to, a second connection receives the MESSAGE). Presumably in that case the reply-to would have to be '/remote-temp-queue/...' or '/remote-temp-topic/...' since the temporary destination actually belongs to the other connection?
                
      was (Author: chris.barrow):
    Wow, thanks for such a quick response! Just want to check my understanding of your fix. Does it mean the received MESSAGE with reply-to ( received as a result of the SEND) will now have reply-to = '/temp-queue/...' or '/temp-topic/...'? 

What about the case where two connections are used (one connection owns the temporary destination and emits the SEND with reply-to, a second connection receives the MESSAGE). Presumably in that case the reply-to would have to be '/remote-temp-queue/...' or '/remote-temp-topic/...' since the queue actually belongs to the other connection?
                  
> STOMP connector: unexpected reply-to value for remote temporary topic
> ---------------------------------------------------------------------
>
>                 Key: AMQ-3543
>                 URL: https://issues.apache.org/jira/browse/AMQ-3543
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: stomp
>    Affects Versions: 5.x
>            Reporter: Christopher Barrow
>            Assignee: Timothy Bish
>            Priority: Minor
>             Fix For: 5.6.0
>
>         Attachments: StompRemoteTempTopic.java
>
>
> The reply-to header on a MESSAGE frame resulting from the sending of a message (SEND) with the reply-to header set to a temporary topic is in the form /temp-topic/<local-temp-topic-name> rather than the expected 
> /remote-temp-topic/<system_generated_name>
> This only happens when the same connection is used for sending and receiving messages. When a temporary queue is used, the reply-to appears as /remote-temp-queue/xxx as expected. So even if one takes the position that it is reasonable for the local name to be used given that everything is on the same connection, there is an inconsistency between the topic and queue cases. For our purposes we would prefer that the remote form be used always, because we are actually servicing two different users on the same connection (first user does the SEND, second user receives the MESSAGE).
> Test case for the underlying ActiveMQ bug is attached: StompRemoteTempTopic.java
> To reproduce, drop this file into $ACTIVEMQ_HOME/example/src, edit build.xml in the example
> directory to add the following:
> <target name="bug" depends="compile" description="Runs test case for replyTo TempTopic bug">
> <echo>Running a Stomp example</echo>
> <java classname="StompRemoteTempTopic" fork="yes" maxmemory="100M">
> <classpath refid="javac.classpath" />
> <jvmarg value="-server" />
> </java>
> </target>
> and run by issuing the command "ant bug". Output is as follows:
> [echo] Running a Stomp example
> [java] =====================================================
> [java] Test run using temporary topic
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Response MESSAGE received
> [java] =====================================================
> [java] Test run using temporary queue
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-queue/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/remote-temp-queue/ID:ChrisBarrow-lap-61815-1318539910206-4:6:1
> [java] Response MESSAGE received
> This makes it easy to see that for the queue case the reply-to is set to the remote temporary queue but for the topic case the local temporary topic is specified.

--
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

        

[jira] [Updated] (AMQ-3543) STOMP connector: unexpected reply-to value for remote temporary topic

Posted by "Christopher Barrow (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/AMQ-3543?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christopher Barrow updated AMQ-3543:
------------------------------------

    Attachment: StompRemoteTempTopic.java
    
> STOMP connector: unexpected reply-to value for remote temporary topic
> ---------------------------------------------------------------------
>
>                 Key: AMQ-3543
>                 URL: https://issues.apache.org/jira/browse/AMQ-3543
>             Project: ActiveMQ
>          Issue Type: Bug
>            Reporter: Christopher Barrow
>            Priority: Minor
>         Attachments: StompRemoteTempTopic.java
>
>
> The reply-to header on a MESSAGE frame resulting from the sending of a message (SEND) with the reply-to header set to a temporary topic is in the form /temp-topic/<local-temp-topic-name> rather than the expected 
> /remote-temp-topic/<system_generated_name>
> This only happens when the same connection is used for sending and receiving messages. When a temporary queue is used, the reply-two appears as /remote-temp-queue/xxx as expected. So even if one takes the position that it is reasonable for the local name to be used given that everything is on the same connection, there is an inconsistency between the topic and queue cases. For our purposes we would prefer that the remote form be used always.
> Test case for the underlying ActiveMQ bug is attached: StompRemoteTempTopic.java
> To reproduce, drop this file into $ACTIVEMQ_HOME/example/src, edit build.xml in the example
> directory to add the following:
> <target name="bug" depends="compile" description="Runs test case for replyTo TempTopic bug">
> <echo>Running a Stomp example</echo>
> <java classname="StompRemoteTempTopic" fork="yes" maxmemory="100M">
> <classpath refid="javac.classpath" />
> <jvmarg value="-server" />
> </java>
> </target>
> and run by issuing the command "ant bug". Output is as follows:
> [echo] Running a Stomp example
> [java] =====================================================
> [java] Test run using temporary topic
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/temp-topic/2C26441740C0ECC9tt1
> [java] Response MESSAGE received
> [java] =====================================================
> [java] Test run using temporary queue
> [java] -----------------------------------------------------
> [java] Sending request message: SEND with reply-to=/temp-queue/2C26441740C0ECC9tt1
> [java] Received request message: MESSAGE with reply-to=/remote-temp-queue/ID:ChrisBarrow-lap-61815-1318539910206-4:6:1
> [java] Response MESSAGE received
> This makes it easy to see that for the queue case the reply-to is set to the remote temporary queue but for the topic case the local temporary topic is specified.

--
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