I have what seems to be a strange memory usage pattern.
First, I am running HornetQ in standalone mode using 64 bit JDK
The following is in my hornetq-configuration.xml
As you can see from above we have set the queue to page a 1GB of memory used. As we load messages, through jconsole, we are seeing the memory usage climbing to 92% of allocated memory (all 5gb of memory have been allocated at this point) before our queue goes to paging. This is the only queue that messages are processing on, and roughly equates to 24000 messages.
I was hoping for a better understanding of what is included in the calculation of the memory used on a queue (is it only the payload of the message?) and what types of other objects might be generated due to using a large number of JMS properties on a message (say 50 String properties per message all less than 40 characters). This is a very odd behavior, and has caused HornetQ to crash on us in the past. It seems like a 5:1 ratio of allocated JVM memory to the max size in bytes for a queue should be more than sufficient to prevent memory related problems.