queues are persistent in hornetQ by default. then why should we configure max-size-bytes and paging with an address? All messages should be stored on disk. there is an example in hornetQ documentation:
<address-settings>
<address-setting match="jms.someaddress">
<max-size-bytes>104857600</max-size-bytes>
<page-size-bytes>10485760</page-size-bytes>
<address-full-policy>PAGE</address-full-policy>
</address-setting>
</address-settings>
Is this for non-persistent queues? or non persistent messages. (it doesn’t mention it in the documentation)
As far as i know, max-size-bytes is the maximum size of the queue in memory, while page-size-bytes is the size of each pagination file in disk.
You might want to define max-size-bytes otherwise you can get your heap memory exhausted. Once you do that, you should define the behavior of the system when a queue max size is reached; you can BLOCK the producer, DISCARD upcoming messages, or PAGINATE into disk. Then you may want to define the size of the pagination files that are going to be created by hornetq when needed.