Bug 737502 - Switching destination syntax from ADDR to BURL and back causes javax.jms.JMSException: Error creating producer (Caused by: org.apache.qpid.AMQException: Ambiguous address...)
Summary: Switching destination syntax from ADDR to BURL and back causes javax.jms.JMSE...
Keywords:
Status: NEW
Alias: None
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: qpid-java
Version: 2.0
Hardware: Unspecified
OS: Unspecified
medium
high
Target Milestone: ---
: ---
Assignee: messaging-bugs
QA Contact: MRG Quality Engineering
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-09-12 11:02 UTC by Zdenek Kraus
Modified: 2018-02-06 16:40 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:


Attachments (Terms of Use)

Description Zdenek Kraus 2011-09-12 11:02:28 UTC
Description of problem:
When subsequentely changing destination syntax for JMS from BURL to ADDR it causes exception thrown
javax.jms.JMSException: Error creating producer (Caused by: org.apache.qpid.AMQException: Ambiguous address...).
Changing destination syntax should be allowed in any way.

Version-Release number of selected component (if applicable):
qpid-java-jca-0.10-7.el6.noarch
qpid-java-common-0.10-7.el6.noarch
qpid-java-example-0.10-7.el6.noarch
qpid-java-client-0.10-7.el6.noarch

OR

qpid-java-jca-0.10-6.el6.noarch
qpid-java-common-0.10-6.el6.noarch
qpid-java-example-0.10-6.el6.noarch
qpid-java-client-0.10-6.el6.noarch


How reproducible:
100%

Steps to Reproduce:
1. cd /usr/share/doc/qpid-java-0.10/example
2. ./run_example org.apache.qpid.example.Hello
could be ./run_example -Dqpid.dest_syntax=ADDR org.apache.qpid.example.Hello
step 2 could be repeated
3. ./run_example -Dqpid.dest_syntax=BURL org.apache.qpid.example.Hello
step 3 could be repeated
4. ./run_example org.apache.qpid.example.Hello
could be ./run_example -Dqpid.dest_syntax=ADDR org.apache.qpid.example.Hello
this will cause JMSException

Actual results:
javax.jms.JMSException: Error creating producer
        at org.apache.qpid.client.AMQSession_0_10.createMessageProducer(AMQSession_0_10.java:689)
        at org.apache.qpid.client.AMQSession_0_10.createMessageProducer(AMQSession_0_10.java:82)
        at org.apache.qpid.client.AMQSession$6.execute(AMQSession.java:2599)
        at org.apache.qpid.client.AMQSession$6.execute(AMQSession.java:2594)
        at org.apache.qpid.client.AMQConnectionDelegate_0_10.executeRetrySupport(AMQConnectionDelegate_0_10.java:322)
        at org.apache.qpid.client.AMQConnection.executeRetrySupport(AMQConnection.java:628)
        at org.apache.qpid.client.failover.FailoverRetrySupport.execute(FailoverRetrySupport.java:102)
        at org.apache.qpid.client.AMQSession.createProducerImpl(AMQSession.java:2592)
        at org.apache.qpid.client.AMQSession.createProducerImpl(AMQSession.java:2586)
        at org.apache.qpid.client.AMQSession.createProducer(AMQSession.java:1199)
        at org.apache.qpid.client.AMQSession.createProducer(AMQSession.java:120)
        at org.apache.qpid.example.Hello.runTest(Hello.java:57)
        at org.apache.qpid.example.Hello.main(Hello.java:40)
Caused by: org.apache.qpid.AMQException: Exception occured while verifying destination
        at org.apache.qpid.client.BasicMessageProducer_0_10.declareDestination(BasicMessageProducer_0_10.java:91)
        at org.apache.qpid.client.BasicMessageProducer.<init>(BasicMessageProducer.java:141)
        at org.apache.qpid.client.BasicMessageProducer_0_10.<init>(BasicMessageProducer_0_10.java:66)
        at org.apache.qpid.client.AMQSession_0_10.createMessageProducer(AMQSession_0_10.java:684)
        ... 12 more
Caused by: org.apache.qpid.AMQException: Ambiguous address, please specify queue or topic as node type
        at org.apache.qpid.client.AMQSession_0_10.resolveAddressType(AMQSession_0_10.java:1282)
        at org.apache.qpid.client.AMQSession_0_10.handleAddressBasedDestination(AMQSession_0_10.java:1187)
        at org.apache.qpid.client.BasicMessageProducer_0_10.declareDestination(BasicMessageProducer_0_10.java:87)
        ... 15 more


Expected results:
Hello world!
'amq.topic'/'#'; {
  'create': 'always'
}

Additional info:


Note You need to log in before you can comment on or make changes to this bug.