We started a sender without a consumer for a point-to-point queue for a day, sending a message per second. In the next day, we restarted the Jboss, then it gave Out of Memory error while starting PersistenceManager, it couldn't load the messages. We noticed that Jboss stored all unconsumed messages (more than 30Mb) in db/jbossmq/file directory as separate files. it took 5 minutes to remove files.
Is there any way to handle such situations in jboss?
I have seen a similar issues when starting JBoss with persistant messages in files. I also had to delete the files before restarting to get it to work.