-
1. Re: Some times it has delay when receving messages
mielket Mar 3, 2009 9:02 AM (in response to shkumesh)How large is the delay that you encounter? Does it only affect the consumers? Does it affect all consumers or just one particular consumer.
You mentioned this problem only happens under high load. Can you give some indications as to how high the load would be?
Also, in addition to your activemq.xml config do you use any other ActiveMQ features such as message selectors, priority queues, or anything else?
-
2. Re: Some times it has delay when receving messages
shkumesh Mar 6, 2009 12:47 AM (in response to mielket)this was happened only for some consumers ,mostly when we try to get messages from high load queues . load is about 50 to 120 messages per second .
We are using priority queues , But with out priority queues this was happened
-
3. Re: Some times it has delay when receving messages
mielket Mar 9, 2009 11:25 AM (in response to shkumesh)>some times it has some delay when receiving messages from queues .
How do you monitor the delay? By looking at the rate at which an individual consumer receives messages? Of what magnitude is the delay? Do you expect all consumers to consume at the same rate?
Do all your consumers connect to the same broker instance? How many consumers are typically connected to the high load queues? Does only a subset of these consumers show a delay or all consumers that are connected to a high load queue?
>But with out priority queues this was happened.
Does it happen irrespective of using priority queues? Do you use message selectors to realize priority queues as outlined here?
-
4. Re: Some times it has delay when receving messages
shkumesh Mar 11, 2009 8:57 AM (in response to mielket)We have 2 brokers,we dnt expect each consumer to consume at same rat,Activemq should send messages at the rate of each consumer ,each consumer has different rate ,depending on rate they do the processing
We are also using prefetch sizes .Are there any particular way of adjusting that ?.
We have used like that
queue : consumer
Issue happens when consuming becomes slow ,then it never recovers,consuming becomes slow .. because of internal processing delays .To resolve this we have to restart active mq .
-
5. Re: Some times it has delay when receving messages
mielket Mar 11, 2009 12:37 PM (in response to shkumesh)I am not sure I really understand the issue. Have you done any monitoring or logging to verify that this is an issue in the broker? You mentioned restarting the broker solves the problem but from what I read so far I am wondering if this could also be an issue in the consumer?
Can you isolate the problem in a testcase by any chance?
You can configure the prefetch size as explained here.
So are you saying that once a consumer gets a bit slower (because of processing time in the consumer itself) it never speeds up again? Are you sure this is not a consumer issue? Generally the broker will send prefetchLimit number of messages to a consumer in one go, then waiting for acks before sending more messages. I don't see how this should slow down the consumer.
-
6. Re: Some times it has delay when receving messages
shkumesh Mar 13, 2009 1:46 AM (in response to mielket)I think this is related to active mq memory releasing . Because when we restarting it will clear all the used memory, then only it working correctly. Are there any method to release unused queue memory in active mq .
-
7. Re: Some times it has delay when receving messages
mielket Mar 13, 2009 6:58 AM (in response to shkumesh)Have you used tools like JConsole to check for an increasing memory consumption inside ActiveMQ? I am not aware of any memory leaks in this regards.
I am not sure how to bring this issue any further without getting more precise information as to where exactly the problem is. If you could narrow down the problem to a particular area and provide supporting measurements or figures that would be of help. Ideally a testcase the reproduces the problem would be of tremendous help.