activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Strachan (JIRA)" <>
Subject [jira] Resolved: (AMQ-1961) Creating two consumers one after the other causes problems dequeuing messages
Date Wed, 01 Oct 2008 14:56:52 GMT


James Strachan resolved AMQ-1961.

    Resolution: Fixed

I don't think this is a bug, just a misunderstanding or misconfiguration of the prefetch size...

setting a prefetch size of 1 or zero should fix your issue - or waiting long enough for messages
to be redispatched to the closed consumer.

> Creating two consumers one after the other causes problems dequeuing messages
> -----------------------------------------------------------------------------
>                 Key: AMQ-1961
>                 URL:
>             Project: ActiveMQ
>          Issue Type: Bug
>    Affects Versions: 5.1.0
>            Reporter: Aaron Pieper
>         Attachments:
> I create a vm queue with ten messages. I then create a consumer, dequeue the top message
(message #1), and close that consumer. If I then create a second consumer, and try to dequeue
the top message (message #2), there is a small chance that this will unexpectedly fail, and
the request will time out. This is one problem.
> After this happens, examining the queue with a queue browser shows message #2 still on
the queue. However, subsequent attempts to dequeue this message will always time out. Messages
#3-10 will be in the same state; they will still be in the queue, but they cannot be dequeued.
This is a worse problem, as it means that we can not reuse this queue.
> The problem arises more frequently as there are more consumers. With two or three consumers,
it comes up sporadically. With twenty or more consumers, it happens almost 100% of the time.
I've attached a test case which demonstrates the bug consistenty.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message