Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 549443 - qpid-config cannot create bindings for the XML or Headers exchange types
qpid-config cannot create bindings for the XML or Headers exchange types
Status: CLOSED ERRATA
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: qpid-qmf (Show other bugs)
1.2
All Linux
medium Severity medium
: 1.3
: ---
Assigned To: Ted Ross
Frantisek Reznicek
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-12-21 12:53 EST by Ted Ross
Modified: 2015-11-15 20:11 EST (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Previously, qpid-config did not provide any access to the "arguments" field of an exchange-bind operation for header and xml exchanges because no binding key was set before the "any" or "all" keyword. With this update, users can specify needed parameters for queue to header and/or xml exchange binding.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-10-14 12:15:24 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2010:0773 normal SHIPPED_LIVE Moderate: Red Hat Enterprise MRG Messaging and Grid Version 1.3 2010-10-14 11:56:44 EDT

  None (edit)
Description Ted Ross 2009-12-21 12:53:34 EST
qpid-config does not provide any access to the "arguments" field of an exchange-bind operation.

For the Headers exchange, the user must be able to specify an operator ('any' or 'all) and a set of key/value pairs.

For the XML exchange, the user must be able to supply an XQuery document.  This could be done via stdin or from an input file.  It would probably be good to use a well-established convention (i.e. "-" for stdin or "-f <filename>" for an input file)
Comment 1 jrd 2010-01-07 15:47:01 EST
Fixed upstream in https://issues.apache.org/jira/browse/QPID-2327
Comment 3 Frantisek Reznicek 2010-09-27 10:43:05 EDT
Although the xlm exchange can be bound using both variants:
  cat /tmp/x.xml |  qpid-config bind xml1 X Y -f -
  qpid-config bind xml1 X Y -f /tmp/x.xml

There is problem with header exchange binding:

[root@mrg-qe-01 bz636262]# qpid-config add queue X
[root@mrg-qe-01 bz636262]# qpid-config add queue Y
[root@mrg-qe-01 bz636262]# qpid-config bind xml1 X X -f /tmp/x.xml
[root@mrg-qe-01 bz636262]# qpid-config bind xml2 Y X -f /tmp/x.xml
[root@mrg-qe-01 bz636262]# qpid-config bind xml2 X -f /tmp/x.xml
[root@mrg-qe-01 bz636262]# qpid-config bind head1 Y all k1=v1
Invalid args to bind headers:  need 'any'/'all' plus conditions
Failed: ValueError: need more than 1 value to unpack
[root@mrg-qe-01 bz636262]# qpid-config bind head1 Y  k1=v1
Invalid args to bind headers:  need 'any'/'all' plus conditions
Failed: ValueError: need more than 1 value to unpack
[root@mrg-qe-01 bz636262]# qpid-config bind head1 X  k1=v1
Invalid args to bind headers:  need 'any'/'all' plus conditions
Failed: ValueError: need more than 1 value to unpack
[root@mrg-qe-01 bz636262]# qpid-config bind head1 X any k1=v1,k2=v2
Invalid args to bind headers:  need 'any'/'all' plus conditions
Failed: ValueError: need more than 1 value to unpack
[root@mrg-qe-01 bz636262]# qpid-config bind head1 X any k1=v1 k2=v2
Invalid condition arg to bind headers, need 'any' or 'all', not 'k1=v1'
Failed: ValueError: need more than 1 value to unpack
[root@mrg-qe-01 bz636262]# qpid-config bind head1 X any k1=v1, k2=v2
Invalid condition arg to bind headers, need 'any' or 'all', not 'k1=v1,'
Failed: ValueError: need more than 1 value to unpack
[root@mrg-qe-01 bz636262]# qpid-config bind head1 X all k1=v1, k2=v2
Invalid condition arg to bind headers, need 'any' or 'all', not 'k1=v1,'
Failed: ValueError: need more than 1 value to unpack
[root@mrg-qe-01 bz636262]# qpid-config bind head1 X all k1=v1,k2=v2
Invalid args to bind headers:  need 'any'/'all' plus conditions
Failed: ValueError: need more than 1 value to unpack
[root@mrg-qe-01 bz636262]# qpid-config bind head1 X all {k1=v1,k2=v2}
Invalid condition arg to bind headers, need 'any' or 'all', not 'k1=v1'
Failed: ValueError: need more than 1 value to unpack
[root@mrg-qe-01 bz636262]# qpid-config bind head1 Y all k1=v1,k2=v2
Invalid args to bind headers:  need 'any'/'all' plus conditions
Failed: ValueError: need more than 1 value to unpack
[root@mrg-qe-01 bz636262]# qpid-config bind head1 Y all k1=v1, k2=v2
Invalid condition arg to bind headers, need 'any' or 'all', not 'k1=v1,'
Failed: ValueError: need more than 1 value to unpack


There seems to be no way how to bind headers exchange. Let me know if I'm missing there something. The source of commands above is from qpid-config --help & permutations/variations.

-> ASSIGNED
Comment 4 Ted Ross 2010-09-27 13:09:09 EDT
The issue here is in the help-string/usage for qpid-config which says the following with regard to the "bind" operation:

  qpid-config [OPTIONS] bind   <exchange-name> <queue-name> [binding-key]
            <for type xml>     [-f -|filename]
            <for type header>  [all|any] k1=v1 [, k2=v2...]

For XML and Headers exchanges, the binding-key is not optional and must be supplied before the "any" or "all" keyword.  In the above report, "all" is being interpreted as the binding key.

The reason the binding key is required is that without it, the binding cannot be deleted.  For XML and Headers exchanges, the binding key serves only as a handle by which a binding can be referred to.
Comment 5 Frantisek Reznicek 2010-09-29 03:40:08 EDT
I can confirm the above comment 4, testing with given <binding-key> works well. I believe qpid-config usage text should be modified or alternatively rel. note should describe this case.
Comment 6 Florian Nadge 2010-10-07 06:26:30 EDT
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
Previously, qpid-config did not provide any access to the "arguments" field of an exchange-bind operation for header and xml exchanges. With this update, users can specify needed parameters for queue to header and/or xml exchange binding.
Comment 7 Florian Nadge 2010-10-07 06:39:47 EDT
    Technical note updated. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    Diffed Contents:
@@ -1 +1 @@
-Previously, qpid-config did not provide any access to the "arguments" field of an exchange-bind operation for header and xml exchanges. With this update, users can specify needed parameters for queue to header and/or xml exchange binding.+Previously, qpid-config did not provide any access to the "arguments" field of an exchange-bind operation for header and xml exchanges because no binding key was set before the "any" or "all" keyword. With this update, users can specify needed parameters (...) for queue to header and/or xml exchange binding.
Comment 8 Jeff Needle 2010-10-08 14:31:16 EDT
Covered by tech note, so moving to VERIFIED
Comment 9 Lana Brindley 2010-10-13 17:23:37 EDT
    Technical note updated. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    Diffed Contents:
@@ -1 +1 @@
-Previously, qpid-config did not provide any access to the "arguments" field of an exchange-bind operation for header and xml exchanges because no binding key was set before the "any" or "all" keyword. With this update, users can specify needed parameters (...) for queue to header and/or xml exchange binding.+Previously, qpid-config did not provide any access to the "arguments" field of an exchange-bind operation for header and xml exchanges because no binding key was set before the "any" or "all" keyword. With this update, users can specify needed parameters for queue to header and/or xml exchange binding.
Comment 11 errata-xmlrpc 2010-10-14 12:15:24 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2010-0773.html

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