com.oracle.howto.activemq
Class ActiveMQEJBBean

java.lang.Object
  extended by com.oracle.howto.activemq.ActiveMQEJBBean
All Implemented Interfaces:
java.io.Serializable, javax.ejb.EnterpriseBean, javax.ejb.SessionBean

public class ActiveMQEJBBean
extends java.lang.Object
implements javax.ejb.SessionBean

This is a Stateless Session Bean which is an example of Outbound Communication using ActiveMQ JCA Resource Adapter The Stateless Session Bean posts a message to ActiveMQ queue "queue.outbound"

See Also:
Serialized Form

Constructor Summary
ActiveMQEJBBean()
           
 
Method Summary
 void ejbActivate()
          Implements the standard api.
 void ejbCreate()
          Implements the standard api.
 void ejbPassivate()
          Implements the standard api.
 void ejbRemove()
          Implements the standard api.
 void sendMessage(java.lang.String recvdmessage)
          Posts a message to ActiveMQ queue "queue.outbound" using recvdMessage
 void setSessionContext(javax.ejb.SessionContext context)
          Implements the standard api.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ActiveMQEJBBean

public ActiveMQEJBBean()
Method Detail

ejbCreate

public void ejbCreate()
Implements the standard api.


setSessionContext

public void setSessionContext(javax.ejb.SessionContext context)
                       throws javax.ejb.EJBException
Implements the standard api.

Specified by:
setSessionContext in interface javax.ejb.SessionBean
Parameters:
context -
Throws:
javax.ejb.EJBException

ejbRemove

public void ejbRemove()
               throws javax.ejb.EJBException
Implements the standard api.

Specified by:
ejbRemove in interface javax.ejb.SessionBean
Throws:
javax.ejb.EJBException

ejbActivate

public void ejbActivate()
                 throws javax.ejb.EJBException
Implements the standard api.

Specified by:
ejbActivate in interface javax.ejb.SessionBean
Throws:
javax.ejb.EJBException

ejbPassivate

public void ejbPassivate()
                  throws javax.ejb.EJBException
Implements the standard api.

Specified by:
ejbPassivate in interface javax.ejb.SessionBean
Throws:
javax.ejb.EJBException

sendMessage

public void sendMessage(java.lang.String recvdmessage)
                 throws javax.naming.NamingException,
                        javax.jms.JMSException
Posts a message to ActiveMQ queue "queue.outbound" using recvdMessage

Parameters:
recvdmessage -
Throws:
javax.naming.NamingException
javax.jms.JMSException