qpid-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oleksandr Rudyy <oru...@gmail.com>
Subject ExecutionException is sent by cpp broker in response for "queue.query" command for a deleted queue
Date Mon, 14 Nov 2011 20:25:57 GMT
Hi,

I would like to bring to your attention that java test
org.apache.qpid.test.client.destination.AddressBasedDestinationTest.testDeleteOptions
started to fail constantly against cpp broker.

The test is written to test a queue deletion if a "delete" option is
specified in address URL.
It tests a queue deletion for all 3 possible values of the delete
option: always, receiver and sender.

For all these cases test creates a producer and a consumer on test
queues and uses "queue.query" command to check the queue existing
after closing the consumer/producer.

On closing the consumer/producer the queue is deleted and
ExecutionResullt with QueueQueryResult object is expected to be
received by the test in response for "queue.query" command.
For delete options  'always' and 'receiver' the received response is
as expected but for delete option 'sender' the
ExecutionException(errorCode=RESOURCE_DELETED, description=Queue
testQueue3 has been deleted. (qpid/broker/Queue.cpp:1415),
errorInfo={}) is sent by the cpp broker on receiving  "queue.query"
command for a deleted queue.

The last case passed before with some sporadic failures from time to
time but now it fails all the time.

Here is the snippet of java code which fails

        Session jmsSession =
_connection.createSession(false,Session.AUTO_ACKNOWLEDGE);
        MessageConsumer cons;

        ....

        String addr3 = "ADDR:testQueue3;{create: always, delete: sender}";
        AMQDestination dest = new AMQAnyDestination(addr3);
        try
        {
            cons = jmsSession.createConsumer(dest);
            MessageProducer prod = jmsSession.createProducer(dest);
            prod.close();
        }
        catch(JMSException e)
        {
            fail("Exception should not be thrown. Exception thrown is : " + e);
        }

        assertFalse("Queue not deleted as expected",(

(AMQSession_0_10)jmsSession).isQueueExist(dest,(QueueNode)dest.getSourceNode(),
true));


The given above code always passes against Java broker.
I raised JIRA https://issues.apache.org/jira/browse/QPID-3576 to track
this issue.
In JIRA description I added a broker/clint log showing the commands
flow between client and broker.

Kind Regards,
Alex

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org


Mime
View raw message