Hi everybody

My colleges and I are looking for a way to have an EJB in the jBoss to get 
messages from a jms message queue (from a SonicMQ jms, to be precise, we 
don�t use the spydermq). We don�t want beans that�s up and running all the 
time listening to the queue so we are looking for ways to make something 
else call the bean, passing the message in the function call instead.
   The approach we have taken is to let a mBean start a jms-queue-listening 
object in a separate running thread. Then when a message arrives to a queue, 
the queue listener gets a �onMessage()�-event and simply calls the EJB as an 
ordinary EJB-client. It seem to work � up to the point when the listener 
makes the �bean = home.create();�. Before that it apparently manages to get 
a reference to the ejb-home interface (the code is not interrupted that far 
anyway).

The error cast is: "java.lang.ClassCastException: $Proxy9"

   If the listeners are run as standalone programs they work as thought. And 
if there are two instances of jBoss � they seem to be able to call the ejb�s 
on the other jBoss instance.

Could somebody tell me if it�s possible to make a call within the jBoss 
instance to an EJB in it - and in that case how?


Thanks

Claes Lundahl

________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com



--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Problems?:           [EMAIL PROTECTED]

Reply via email to