2

I've been experiencing an issue on the consumer side when restarting. After dumping the heap and sifting through threads, I've determined that the issue is due to the compression of the kahadb local repository index file. As this file gets larger, the time it takes for the consumer to start getting messages again increases. I've deleted my local repository directory, restarted, and verified that the consumer gets messages almost instantly.

Has anyone experienced this issue when working with ActiveMQ and KahaDB? On occasion, if the directory isn't wiped out, it can take up to 1.5 hours for my consumer to start getting messages from the broker again.

I've also verified that the messages are being published in a timely matter, they're just not being consumed because the index compression thread is blocking the "add" threads.

Any insight would be greatly appreciated!

4
  • Have you looked into using levelDB instead (activemq.apache.org/leveldb-store.html) It has a totally different way to write indices to disk so, it might help you out. It seems to be the preferred persistence store in future versions of AMQ as well Jul 7, 2013 at 9:34
  • Thanks for the response! I've stepped into a pre-existing project which is leveraging ActiveMQ 5.5.1. According to the web site you pointed me to, the levelDB store is only supported in ActiveMQ 5.8.0 and higher.
    – Jason King
    Jul 8, 2013 at 15:16
  • The file should not get incredibly large. Do you commit the persistent messages on the consumer side once you processed them? Have you tried running the broker with persistence disabled to see if you also get that slowdown?
    – SirRichie
    Jul 16, 2013 at 14:32
  • I was able to resolve this issue. There was a bug in the purge strategy for the consumer, causing it never to be called. The persistent messages were never being removed after they were processed, causing an incredibly long startup process everything was reindexed.
    – Jason King
    Jul 16, 2013 at 18:27

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.