I am doing a Proof-of-concept for a scenario of scheduled messaging in JBoss 5.1. The use case is this:
I am firing up a message of a 1 MB payload to a locally configured JBoss queue, in a loop, 600 times. I am using JMS_JBOSS_SCHEDULED_DELIVERY property set in the message object and the timer is set to 600000 ms (10 minutes). During the 10 minutes the messages are fired and not consumed by the MDB, the size of the localDB.script file in \server\all\data\hypersonic swells up to about 1.2 GB (which is about 2 MB per message payload - this is because JBoss converts the payload into hexadecimal and that gets stored in the Hypersonic DB). All that is fine, I guess. But after the MDB consumes the messages, and the queue is back to no messages, the size of the localDB.script file still stays at 1.2 GB, until I restart the JBoss server instance. I do not think that this is correct.
On the other hand, if I fire the same messages, with immediate delivery (no scheduled delivery setting), this behaviour is not observed.
I need to use JMS_JBOSS_SCHEDULED_DELIVERY and would like to know if there is a solution to the localDB.script's swelling up. As I said, this does not look to be right behaviour. Any leads, suggestions would be greatly appreciated!