Bug 996100

Summary: [AMQP 1.0] set address for 'local' terminus
Product: Red Hat Enterprise MRG Reporter: Gordon Sim <gsim>
Component: qpid-cppAssignee: Gordon Sim <gsim>
Status: CLOSED CURRENTRELEASE QA Contact: Ernie <eallen>
Severity: unspecified Docs Contact:
Priority: low    
Version: DevelopmentCC: eallen, esammons, freznice, gsim, iboverma, jross, mtoth, pematous
Target Milestone: 3.0Keywords: OtherQA
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: qpid-cpp-0.22-11 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1010399    

Description Gordon Sim 2013-08-12 12:08:36 UTC
Description of problem:

When establishing a receiver, the qpid::messaging client will only populate the address for the source. Likewise when creating a sender it will only populate the address of the target.

For some cases (using the client against Qpid Dispatch for example) it may be desired to have the source set for a sender and the target set for a receiver.

Version-Release number of selected component (if applicable):

qpid-0.22

How reproducible:

100% but its a little involved

Steps to Reproduce:

Either turn on trace logging  for the protocol and observe the frames being sent

Or, try to use qpid::messaging against the qpid dispatch router: start the router, start receivers for any address over 1.0, send a message to the router with that address in the to field (can use -P x-amqp-to=abc with spout or qpid-send).


Actual results:

Target not set for receivers (and qpid dispatch router thus not able to route the messages)

Expected results:

Target set for receivers and source set for senders. Qpid dispatch router able to route messages to qpid::messaging receivers.

Additional info:

By default the source of receivers is used to populate the target and the target of sender is used to populate the source. However this can be changed by specifying either receiver-target or sender-source in the link properties.

Though this doesn't affect current product, it would be desirable for released versions to be able to be used with upcoming developments like qpid dispatch.

Comment 1 Gordon Sim 2013-08-12 12:09:26 UTC
Fixed upstream by https://svn.apache.org/r1508523 and https://svn.apache.org/r1508832

Comment 2 Irina Boverman 2013-08-13 19:48:35 UTC
Hi Gordon,
I applied https://svn.apache.org/r1508523, but https://svn.apache.org/r1508832 had a conflict on 0.22-mrg branch, can you please make appropriate changes and commit to a private branch?

Comment 3 Gordon Sim 2013-08-14 11:28:21 UTC
Backported second svn commit to http://git.app.eng.bos.redhat.com/?p=rh-qpid.git;a=shortlog;h=refs/heads/0.22-mrg-BZ996100

Comment 4 Ernie 2014-04-04 14:42:30 UTC
Verified RHEL 6.5 64 with help from Mick Goulish
on package 0.22-36

in qpidd.conf:
log-enable=trace+
log-enable=trace+:Protocol

./server amqp:tcp:127.0.0.1:5672  '{protocol:amqp1.0}' &
./client amqp:tcp:127.0.0.1:5672  '{protocol:amqp1.0}'

Verified by enabling Protocol logging and inspecting the source and target
2014-04-04 10:06:56 [Protocol] trace /builddir/build/BUILD/qpid-0.22/cpp/src/qpid/broker/amqp/Connection.cpp:66: [qpid.127.0.0.1:5672-127.0.0.1:42506]: 0 <- @attach(18) [name="service_queue_58e9c12b-04d1-45c7-85a1-8165dbdaeceb", handle=0, role=true, snd-settle-mode=2, rcv-settle-mode=0, source=@source(40) [address="service_queue", durable=0, timeout=0, dynamic=false, capabilities=:"create-on-demand"], target=@target(41) [address="service_queue", durable=0, timeout=0, dynamic=false], initial-delivery-count=0]

Also tried using qpid-send and verifying the source is set, and using qpid-receive and verifying the target is set.