OutOfMemoryError in ActiveMQ Broker due to large KahaDB PageFile instance

Solution Verified - Updated -

Issue

The ActiveMQ broker runs out of memory:
java.lang.OutOfMemoryError: Java heap space.

Upon inspection of the heap dump that was written at the time of the OutOfMemoryError , it shows a large instance of org.apache.activemq.store.kahadb.KahaDBStore, retaining several hundred MB of JVM heap.

This instance internally references a org.apache.activemq.store.kahadb.disk.page.PageFile which accumulates around the same amount of heap space.

This PageFile instance holds a reference to org.apache.activemq.util.LRUCache that contains 10,000 entries and retains most of the heap space.

Environment

  • JBoss Fuse 6.3 R5

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.