I am implementing an event handler using MDB and i am using jboss-5.1.0.GA. In my case, whenever jboss starts up my MDB (constructor should be called) should get instantiated , so that whenever message comes to the queue my onMessage() method will be invoked for message processing. In my MDB constructor i am doining instantiation of other required classes for message processing.
Issue: But now the issue is my MDB constructor is getting called only after the message comes to the queue, becuase of this my message processing(onMessage call) is getting delayed.
Could you please tell me how to instantiate pool of MDB's when JBoss starts up?
Thanks in advance!!
My MDB code looks like this:
Queue configuration in Jboss looks like this:destinations-service.xml