Bug 619242

Summary: Incorrect logic when querying for existence of an exchange while parsing an address string.
Product: Red Hat Enterprise MRG Reporter: Rajith Attapattu <rattapat+nobody>
Component: qpid-javaAssignee: Rajith Attapattu <rattapat+nobody>
Status: CLOSED CURRENTRELEASE QA Contact: MRG Quality Engineering <mrgqe-bugs>
Severity: medium Docs Contact:
Priority: low    
Version: DevelopmentCC: jross
Target Milestone: 1.3   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: 0.10 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-02-25 10:50:17 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Rajith Attapattu 2010-07-29 01:51:40 UTC
Description of problem:
Consider the following address string,
"HELLO/world; {create: never, node: { type: topic }}", where HELLO is a pre existing exchange of type 'direct'.

Since the type of the exchange is not specified, the Java client defaults to 'topic' right at the beginning and incorrectly compares the exchange type when querying for the exchange.
The default exchange type should only be specified if an exchange needs to be created and the type is missing.

How reproducible:
Always

Steps to Reproduce:
1. Create an exchange called HELLO with type 'direct'.
2. Pass the following to the Java Drain/Spout example
   "HELLO/world; {create: never, node: { type: topic }}"
3. Observe that the JMS client complains that the exchange is not found.
  
Actual results:
The JMS client throws an exception saying the exchange is not found.

Expected results:
The JMS client should be able to verify the exchange successfully.

Comment 1 Rajith Attapattu 2010-07-29 13:43:26 UTC
This is fixed in upstream (tracked via QPID-2774)
http://svn.apache.org/viewcvs?view=rev&rev=980259

Git commit URL
http://mrg1.lab.bos.redhat.com/cgit/qpid.git/commit/?id=1a2e20b0b6ac865d5d438877696c2068ed92bba2