I am testing ActiveMQ 4.0 with JBoss 4.0 where I am using ActiveMQ's .rar file within JBoss. I have a test applicacation that consists of following components:
-Message driven bean listens to queue within JBoss. It receives message and invokes stateless session bean, which invokes entity bean and the message is added to the databsae (mysql). After adding message, it replies back the response to the client.
-JBoss stateless session bean – uses entity bean to add message to the database
-JBoss entity bean that uses CMP to add message to the database.
-Publisher client - uses ActiveMQ APIs to publish message to the queue and listens for response
I find that after about 2200 messages, I get OutOfMemory exception in ActiveMQ and my application hangs. I am also attaching source code minus jar files.
You will also need mysql database.