activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rob Janney (JIRA)" <j...@apache.org>
Subject [jira] Commented: (AMQ-2952) Message groups with small prefetch
Date Fri, 29 Oct 2010 18:30:01 GMT

    [ https://issues.apache.org/activemq/browse/AMQ-2952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=62927#action_62927
] 

Rob Janney commented on AMQ-2952:
---------------------------------

We ran into this issue with one of our 5.4.1 AMQ instances in production.  We found that once
all consumers are full, the remaining messages are all assigned to a single consumer.  When
we reproduced this issue in test & stepped through the Queue class in AMQ, we found that
this happens because the group logic is done before the full detection.

For example, we had 15 consumers with a prefetch size of 1 and a backlog of 1000 messages.
 Each consumer had at least 1 message assigned to it & some had a few more than that (possibly
finished processing the first message before all consumers were full).  Once all 15 consumers
were full, the remaining 980 or so messages were assigned to the same consumer :(  This lead
to a significant performance problem where we had all the work waiting on a single thread
and the other 14 threads idle doing nothing.

We were able to work around this problem by setting the pre-fetch to 100 for our 15 consumers.
  This allowed the messages to be dispatched in a  round-robin fashion to the first 1500 messages
in the queue.

The fix above to only do group operations on non-full consumers should also resolve the effect
we observed.

> Message groups with small prefetch
> ----------------------------------
>
>                 Key: AMQ-2952
>                 URL: https://issues.apache.org/activemq/browse/AMQ-2952
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 5.4.1
>            Reporter: Dejan Bosanac
>            Assignee: Dejan Bosanac
>             Fix For: 5.5.0
>
>
> Closing and starting message groups with a lot of consumers and a small prefetch could
result in messages being dispatched to wrong consumers. The problem is that message group
logic is done before we detecting weather the consumer is full or not. 

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


Mime
View raw message