Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Anyone used LevelDB store for ActiveMQ message persistence?

At present we are using KahaDB store for message persistence in ActiveMQ and so far good.
As per the release notes of ActiveMQ5.6, LevelDB provides enhanced performance.
Has anyone tried usign LevelDB and if so could you provide the pros and cons?

like image 549
srini Avatar asked Aug 02 '12 00:08

srini


3 Answers

FYI: Here's a link to the official docs for the ActiveMQ LevelDB Store

Cons:

  • It's a brand new store, so may still have some bugs left in it.
  • LevelDB indexes need to 'compact' occasionally which MIGHT stall out new writes.
  • You can't just delete the index and rebuild it from the data files like you can with KahaDB
  • KahaDB handles disk corruption much more gracefully, recovering what it can and discarding corrupted records.

Pros:

  • Append mostly disk access patterns improve perf on rotational disk.
  • Fewer disk syncs than KahaDB
  • Fewer index entries need to be inserted per message stored
  • Fewer index lookups needed to load a message from disk into memory
  • Uses Snappy compression to reduce the on disk size of index entries
  • Optional Snappy compression of data logs.
  • A send to a composite destination only stores the message on disk once.
  • Faster and more frequent data file GCs.
  • Has a 'Replicated' variation where it can self replicate to 'slave' brokers to ensure message level HA.
like image 158
Hiram Chirino Avatar answered Nov 07 '22 00:11

Hiram Chirino


We've been using the levelDB store a month of two now in production on NFS (with standard file lock failover configured). We've had a corrupt store several times now in the last few weeks, with no errors in the logs... just queues piling up, and very low throughput. The only thing we could do to resolve this, is throw away the store, and start over.

So we've switched back to the old and reliable KahaDB store again for now.

like image 5
voodooless Avatar answered Nov 07 '22 00:11

voodooless


Please see this link: https://github.com/fusesource/fuse-extra/tree/master/fusemq-leveldb#how-to-use-with-activemq-56 There's a small comparison for leveldb vs kahadb.

I am currently trying it out on a system with high message throughput , and I see better results already. I still need to see if it is stable, but so far good.

like image 3
inglor Avatar answered Nov 06 '22 23:11

inglor