Bug 688169 - Predefined exchanges / queues are displayed by qpid-config even if deleted
Summary: Predefined exchanges / queues are displayed by qpid-config even if deleted
Keywords:
Status: NEW
Alias: None
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: qpid-qmf
Version: 1.3
Hardware: Unspecified
OS: Unspecified
low
unspecified
Target Milestone: ---
: ---
Assignee: messaging-bugs
QA Contact: MRG Quality Engineering
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-03-16 14:20 UTC by Petr Matousek
Modified: 2021-03-16 12:47 UTC (History)
1 user (show)

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


Attachments (Terms of Use)

Description Petr Matousek 2011-03-16 14:20:03 UTC
Description of problem:

Predefined queues/exchanges are deletable, but after deletion they are still listed using qpid-config tool. 

Exchanges:
Default exchanges qmf.default.direct and qmf.default.topic can be deleted.
The exchanges are still listed with 'qpid-config exchanges' command after deletion.

Queues:
replication-queue created on broker start using following lines in configuration file:
replication-queue=replication-queue
create-replication-queue=true

The queue can be deleted, but the queue is listed using 'qpid-config queues' command after deletion as well.

Please see additional info.

I am not sure about the correct behaviour. There are two options:
1. It is not permitted to delete these predefined queues/exchanges and appropriate error message shall appear on deletion. qpid-config return code shall be non-zero. 
2. It is allowed to delete these predefined queues/exchanges and they shall not 
be listed after deletion anymore.

This was seen on RHEL5.6 x86_64

Version-Release number of selected component (if applicable):
python-qpid-0.9.1079482-1.el5
python-qpid-qmf-0.9.1079953-3.el5
qpid-cpp-client-0.9.1079953-1.el5
qpid-cpp-client-devel-0.9.1079953-1.el5
qpid-cpp-client-devel-docs-0.9.1079953-1.el5
qpid-cpp-client-ssl-0.9.1079953-1.el5
qpid-cpp-mrg-debuginfo-0.9.1079953-1.el5
qpid-cpp-server-0.9.1079953-1.el5
qpid-cpp-server-cluster-0.9.1079953-1.el5
qpid-cpp-server-devel-0.9.1079953-1.el5
qpid-cpp-server-ssl-0.9.1079953-1.el5
qpid-cpp-server-store-0.9.1079953-1.el5
qpid-cpp-server-xml-0.9.1079953-1.el5
qpid-java-client-0.9.1080013-2.el5
qpid-java-common-0.9.1080013-2.el5
qpid-java-example-0.9.1080013-2.el5
qpid-qmf-0.9.1079953-3.el5
qpid-qmf-devel-0.9.1079953-3.el5
qpid-tools-0.9.1078967-1.el5


How reproducible:
100%

Steps to Reproduce:
Please see additional info.
  
Actual results:
User is able to delete predefined queues/exchanges, but
they are still listed using qpid-config tool after deletion. 

Expected results:
Predefined queues/exchanges cannot be deleted, appropriate error message shall be displayed on deletion attempt, return code shall be non-zero. 

or

Predefined queues/exchanges can be deleted, they are not listed with qpid-config tool anymore.

Additional info:

EXCHANGES:

# qpid-config exchanges
Type      Exchange Name       Attributes
==================================================
direct                       
direct    amq.direct          --durable
fanout    amq.fanout          --durable
headers   amq.match           --durable
topic     amq.topic           --durable
direct    qmf.default.direct 
topic     qmf.default.topic  
topic     qpid.management    
# ./spout qmf.default.direct
Message(properties={'spout-id': '9e3e54b0-74db-a849-b644-b9454d13ccd9:0'})
# qpid-config del exchange qmf.default.direct
# echo $?
0
# qpid-config exchanges
Type      Exchange Name       Attributes
==================================================
direct                       
direct    amq.direct          --durable
fanout    amq.fanout          --durable
headers   amq.match           --durable
topic     amq.topic           --durable
direct    qmf.default.direct 
topic     qmf.default.topic  
topic     qpid.management    
# qpid-config del exchange qmf.default.direct
Failed: SessionException: ExecutionException(error_code=404, command_id=serial(47), class_code=7, command_code=2, field_index=0, description=u'not-found: Exchange not found: qmf.default.direct (qpid/broker/ExchangeRegistry.cpp:93)', error_info={}, channel=1, id=serial(61))
# ./spout qmf.default.direct
Traceback (most recent call last):
  File "./spout", line 101, in ?
    snd = ssn.sender(addr)
  File "<string>", line 6, in sender
  File "/usr/lib/python2.4/site-packages/qpid/messaging/endpoints.py", line 582, in sender
    raise e
qpid.messaging.exceptions.NotFound: no such queue: qmf.default.direct



QUEUES:

# cat /etc/qpidd.conf
replication-queue=replication-queue
create-replication-queue=true

# service qpidd start
Starting Qpid AMQP daemon:                                 [  OK  ]
# qpid-config queues
Queue Name                                             Attributes
===========================================================================
qmfagent-f5009e7d-47d0-4b3b-acb8-e97606f9740e          auto-del excl 
qmfc-v2-dhcp-37-228.lab.eng.brq.redhat.com.13223.1     auto-del excl 
qmfc-v2-hb-dhcp-37-228.lab.eng.brq.redhat.com.13223.1  auto-del excl --limit-policy=ring 
qmfc-v2-ui-dhcp-37-228.lab.eng.brq.redhat.com.13223.1  auto-del excl --limit-policy=ring 
replication-queue                                      
reply-dhcp-37-228.lab.eng.brq.redhat.com.13223.1       auto-del excl 
topic-dhcp-37-228.lab.eng.brq.redhat.com.13223.1       auto-del excl --limit-policy=ring 
# ./spout replication-queue
Message(properties={'spout-id': '147307e6-04af-ce4b-81bd-b0b4ac55d942:0'})
# qpid-config del queue replication-queue
# echo $?
0
# qpid-config queues
Queue Name                                             Attributes
===========================================================================
qmfagent-f5009e7d-47d0-4b3b-acb8-e97606f9740e          auto-del excl 
qmfc-v2-dhcp-37-228.lab.eng.brq.redhat.com.13245.1     auto-del excl 
qmfc-v2-hb-dhcp-37-228.lab.eng.brq.redhat.com.13245.1  auto-del excl --limit-policy=ring 
qmfc-v2-ui-dhcp-37-228.lab.eng.brq.redhat.com.13245.1  auto-del excl --limit-policy=ring 
replication-queue                                      
reply-dhcp-37-228.lab.eng.brq.redhat.com.13245.1       auto-del excl 
topic-dhcp-37-228.lab.eng.brq.redhat.com.13245.1       auto-del excl --limit-policy=ring 
# qpid-config del queue replication-queue
Failed: SessionException: ExecutionException(error_code=404, command_id=serial(66), class_code=8, command_code=2, field_index=0, description=u'not-found: Delete failed. No such queue: replication-queue (qpid/broker/Broker.cpp:825)', error_info={}, channel=1, id=serial(64))
# ./spout replication-queue
Traceback (most recent call last):
  File "./spout", line 101, in ?
    snd = ssn.sender(addr)
  File "<string>", line 6, in sender
  File "/usr/lib/python2.4/site-packages/qpid/messaging/endpoints.py", line 582, in sender
    raise e
qpid.messaging.exceptions.NotFound: no such queue: replication-queue


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