Message Driven Bean and Distributed transaction

Hi ALL
I am developing an asynchronous application using MDB. My application flow is as follows:
1. From MDB onMessage i am calling a method MethodA that
a. calls a simple pojo1 where I am getting a Connection on XA enable datasource1 and executing Stored Procedure1 of DatabaseSchema1.
b. In that pojo without committing m closing the connection and coming back in MethodA.
c. Again from MethodA m calling a different pojo2 where I am getting a new Connection on XA enable datasource2 and executing Stored Procedure2 of
DatabaseSchema1. In this pojo also without committing m closing the connection and coming back in MethodA.
d. Again from MethodA m calling pojo1 where I am getting a new Connection on XA enable datasource1 and executing a different function of Stored Procedure1 of DatabaseSchema1.
Public class MDB{
Public void onMessage(��.)
Try{
Method1();
Catch(Exception x)
mdbcontext.setRollbackOnly();
Private void MethodA()
Call pojo1;
Call pojo2
Pojo1
Public void CallSP1()
Get connection from Datasource1 (shema1,user1, pwd1);
Call sp1();
//return without commit;
Pojo2
Public void CallSP2()
Get connection from Datasource2 (shema1,user2, pwd2);
Call sp2();
//return without commit;
SP1:
Insert table1
Savepoint 1
Insert into Table1
Rollback to 1
Insert a row
End SP1 (without commit)
SP2:
Insert table2
Savepoint 2
Update table2
Rollback to 2
Insert table2
End SP2 (without commit)
In ejb-jar.xml
Transaction type is Container
Transaction attribute is Required for all
Now problem is:
Case 1: success case when no exception is there at Java layer
SP1 works fine I mean there is only 2 inserts in Table 1
But In SP2 there are 3 inserts
Case 2: if an exception comes at Java layer
SP1 is fine
Rollback is not happening in SP2
In ejb-jar.xml transaction attributes is Required for all methods and transaction type is Container.
Backend is Oracle 10g and init.xa has already been run on that.
Will be very obliged if can have a single hint of the problem.
Both datasource are XA enable
Backend is Oracle 10g
Application server is WAS 6.0
Queue is WAS MQ 6.0
Thanks

{color:#008000}Hi Friends,
Thought of updating the answers for my questions in case somebody else would find it helpful.
{color}
{color:#999999}{color:#00ccff}I'm trying to make message driven bean and use the OnListener method.
But since I'm doing this for the first time I have very limited knowledge.
The following are my doubts :
1. Should I have a main function while using the MDB?{color}
{color:#008000} There is no need for any main function.{color}
{color:#00ccff}2. Is it mandatory to have JNDI setup done?
{color} {color}{color:#008000} There is no need for any JNDI setup done. But you need to configure the details on the
Websphere by creating valid entries inside Resources namely -
Queue Connection Factory, Queues and Listener Ports under the server.
Thanks,
Arun Prithviraj{color}

Similar Messages

  • Message Driven Bean and transaction handling

    We are using container managed transactions with MDB's running on OC4J version 10.1.2. We have two database serveres, both running Oracle 10g.
    The MDB consume messages from the AQ-database through JMS (connected to a JDBC datasource registered as "jdbc/OracleAQDS").
    The MDB onMessage() code update the second database, using a JDBC datasource registered as "jdbc/OracleDBDS".
    We need atomic behaviour - if the MDB enforce a roll-back we want the updates aginst the second database to be rolled-back as well.
    (1) Should we use XA-datasources since AQ and DB runs on two different servers or do the OC4J container "magically" provide two-phase-commit for us?
    (2) If the MDB does a roll-back we would like to add an error record to a database table. Can we configure a third datasource and prevent if from beeing part of the container managed MDB roll-back?
    (3) When the MDB force a roll-back, is there some way for us to override the retry-delay in our Java code? If we catch certain errors during processing in onMessage we know that it is not necessary to retry for at least one hour (while less severe errors should be retried in just seconds).

    {color:#008000}Hi Friends,
    Thought of updating the answers for my questions in case somebody else would find it helpful.
    {color}
    {color:#999999}{color:#00ccff}I'm trying to make message driven bean and use the OnListener method.
    But since I'm doing this for the first time I have very limited knowledge.
    The following are my doubts :
    1. Should I have a main function while using the MDB?{color}
    {color:#008000} There is no need for any main function.{color}
    {color:#00ccff}2. Is it mandatory to have JNDI setup done?
    {color} {color}{color:#008000} There is no need for any JNDI setup done. But you need to configure the details on the
    Websphere by creating valid entries inside Resources namely -
    Queue Connection Factory, Queues and Listener Ports under the server.
    Thanks,
    Arun Prithviraj{color}

  • Message driven beans and object binding

              I want to write a message driven bean, and use javax.naming.Context's "bind(String,
              Object)" method to bind the data to a key and eventually do a unbind(String) to
              look up the data . Is binding/unbinding of object is allowed inside a message
              driven bean or this violates the EJB2.0 spec? Also, does this have any negative
              consequences if I use a Weblogic cluster as opposed to a single instance? Any
              suggestions
              

    Hi Austin,
              - I don't know if it is "legal" in EJB 2.0
              to call bind/unbind within an MDB. I
              would assume so, but I'm not sure. You can try confirming with
              the jndi and ejb newsgroups. Of course, if you don't
              ask, then no one can tell you "no". ;-)
              - Bind/unbind is a relatively expensive call performance-wise. I
              suspect one might want to avoid doing too many of these per
              second (the jndi newsgroup may be able to give pointers here.)
              - Servers in a cluster do not instantly propagate bind/unbind info
              to other servers in cluster, and JNDI may have trouble
              efficiently supporting larger objects: both potential drawbacks
              to using JNDI for data caching purposes.
              Tom, BEA
              Austin P wrote:
              > I want to write a message driven bean, and use javax.naming.Context's "bind(String,
              > Object)" method to bind the data to a key and eventually do a unbind(String) to
              > look up the data . Is binding/unbinding of object is allowed inside a message
              > driven bean or this violates the EJB2.0 spec? Also, does this have any negative
              > consequences if I use a Weblogic cluster as opposed to a single instance? Any
              > suggestions
              

  • Message driven bean and JDBC Pool

              I am working with weblogic 7.0
              I have created a message driven bean the receives messages and store them in the
              database.
              for performance issue I have put the (SQL)Connection and a preparedStatement in
              the ejbCreate() method ...and I close them in the ejbRemove() method...but I notice
              that the ejbRemove dose not called ... even when I restart the weblogic7.0
              I notice also that when I deploy the the Message driven bean ...it consume a number
              of connections equals the number of instances created by weblogic.
              if I redeploy the message driven bean ...the weblogic consume anthor connections
              without free up the previous connections.
              thank you for any help
              

              Hi,
              EjbRemove will never be called for a message driven bean as it follows the lifecycle
              of a StatlessSession.
              http://e-docs.bea.com/wls/docs61/ejb/EJB_environment.html#1039510
              The container will call EJBRemove only when it gets a RemoteRuntimeException and
              has to recycle the bean.
              -Vimala Ranganathan
              "eyad" <[email protected]> wrote:
              >
              >I am working with weblogic 7.0
              >
              >I have created a message driven bean the receives messages and store
              >them in the
              >database.
              >for performance issue I have put the (SQL)Connection and a preparedStatement
              >in
              >the ejbCreate() method ...and I close them in the ejbRemove() method...but
              >I notice
              >that the ejbRemove dose not called ... even when I restart the weblogic7.0
              >
              >I notice also that when I deploy the the Message driven bean ...it consume
              >a number
              >of connections equals the number of instances created by weblogic.
              >if I redeploy the message driven bean ...the weblogic consume anthor
              >connections
              >without free up the previous connections.
              >thank you for any help
              >
              

  • WLS Cluster with Message Driven Beans and MQSeries on more than one Host

              With the Examples of http://developer.bea.com/jmsproviders.jsp and http://developer.bea.com/jmsmdb.jsp
              a MDB can be
              configured to work with MQSeries with one WLS Server. This works only, if a Queuemanager
              is started at the same Host that runs the WLS Server too.
              And the QueueConnectionFactory (QCF) is configured to TRANSPORT(BIND).
              In my configuration should be two WLS Servers and one JMS Queue (MQS) with the
              Queuemanager.
              A Message Driven Bean is deployed on both WLS Servers wich should get the Messages
              of this Queue.
              If one of the two WLS Servers fails the other WLS Server with the corresponding
              MDB should get the Messages of the
              MQSeries Queue.
              If the QCF is configured to TRANSPORT(Client) the Message Driven Bean can't start
              and the following Exception is thrown:
              <Jul 18, 2001 3:52:49 PM CEST> <Error> <J2EE> <Error deploying EJB Component :
              mdb_deployed
              weblogic.ejb20.EJBDeploymentException: Error deploying Message-Driven EJB:; nested
              exception is:
              javax.jms.JMSException: MQJMS2005: failed to create MQQueueManager for
              'btsun1a:TEST'
              javax.jms.JMSException: MQJMS2005: failed to create MQQueueManager for 'btsun1a:TEST'
              at com.ibm.mq.jms.services.ConfigEnvironment.newException(ConfigEnvironment.java:434)
              I'm wondering, because their is a MQQueueManager on btsun1a; all Servers throws
              the same Exception when the MDB is deployed.
              The configuration of JMSadmin on both Hosts is the following:
              dis qcf(myQCF2)
              HOSTNAME(btsun1a)
              CCSID(819)
              TRANSPORT(CLIENT)
              PORT(1414)
              TEMPMODEL(SYSTEM.DEFAULT.MODEL.QUEUE)
              QMANAGER(TEST)
              CHANNEL(JAVA.CHANNEL)
              VERSION(1)
              dis q(myQueue)
              CCSID(819)
              PERSISTENCE(APP)
              TARGCLIENT(JMS)
              QUEUE(MYQUEUE)
              EXPIRY(APP)
              QMANAGER(TEST)
              ENCODING(NATIVE)
              VERSION(1)
              PRIORITY(APP)
              I think only TRANSPORT(CLIENT) can be used when i don't wan't to install a Queue
              and a QueueManager on each WLS Server.
              Does anybody know a problem of WLS 6.0 SP2 to cope with TRANSPORT(CLIENT)?
              

              With the Examples of http://developer.bea.com/jmsproviders.jsp and http://developer.bea.com/jmsmdb.jsp
              a MDB can be
              configured to work with MQSeries with one WLS Server. This works only, if a Queuemanager
              is started at the same Host that runs the WLS Server too.
              And the QueueConnectionFactory (QCF) is configured to TRANSPORT(BIND).
              In my configuration should be two WLS Servers and one JMS Queue (MQS) with the
              Queuemanager.
              A Message Driven Bean is deployed on both WLS Servers wich should get the Messages
              of this Queue.
              If one of the two WLS Servers fails the other WLS Server with the corresponding
              MDB should get the Messages of the
              MQSeries Queue.
              If the QCF is configured to TRANSPORT(Client) the Message Driven Bean can't start
              and the following Exception is thrown:
              <Jul 18, 2001 3:52:49 PM CEST> <Error> <J2EE> <Error deploying EJB Component :
              mdb_deployed
              weblogic.ejb20.EJBDeploymentException: Error deploying Message-Driven EJB:; nested
              exception is:
              javax.jms.JMSException: MQJMS2005: failed to create MQQueueManager for
              'btsun1a:TEST'
              javax.jms.JMSException: MQJMS2005: failed to create MQQueueManager for 'btsun1a:TEST'
              at com.ibm.mq.jms.services.ConfigEnvironment.newException(ConfigEnvironment.java:434)
              I'm wondering, because their is a MQQueueManager on btsun1a; all Servers throws
              the same Exception when the MDB is deployed.
              The configuration of JMSadmin on both Hosts is the following:
              dis qcf(myQCF2)
              HOSTNAME(btsun1a)
              CCSID(819)
              TRANSPORT(CLIENT)
              PORT(1414)
              TEMPMODEL(SYSTEM.DEFAULT.MODEL.QUEUE)
              QMANAGER(TEST)
              CHANNEL(JAVA.CHANNEL)
              VERSION(1)
              dis q(myQueue)
              CCSID(819)
              PERSISTENCE(APP)
              TARGCLIENT(JMS)
              QUEUE(MYQUEUE)
              EXPIRY(APP)
              QMANAGER(TEST)
              ENCODING(NATIVE)
              VERSION(1)
              PRIORITY(APP)
              I think only TRANSPORT(CLIENT) can be used when i don't wan't to install a Queue
              and a QueueManager on each WLS Server.
              Does anybody know a problem of WLS 6.0 SP2 to cope with TRANSPORT(CLIENT)?
              

  • Message driven bean and security

    Hi there!
    I need to apply security capability during analyzing incoming messages.
    Details:
    I have an Entity bean with one method restricted by security to access. But
    one of requirements is to provide this method call also in asynchronous way.
    So I add Message Driven Bean that will call method of entity. But it's a
    security violation.
    So, can anybody advise how to provide security in conjunction with MDB?
    Thank you in advance.

    Hi Max,
    I think the problem is that you have no context with which to pass the security
    credentials. You need someway to pass the credentials.
    Kind Regards,
    Richard Wallace
    Senior Developer Relations Engineer
    BEA Support.
    "Max" <[email protected]> wrote:
    Hi there!
    I need to apply security capability during analyzing incoming messages.
    Details:
    I have an Entity bean with one method restricted by security to access.
    But
    one of requirements is to provide this method call also in asynchronous
    way.
    So I add Message Driven Bean that will call method of entity. But it's
    a
    security violation.
    So, can anybody advise how to provide security in conjunction with MDB?
    Thank you in advance.

  • Message driven bean and message style web service

    Hi,
    I'm trying to deploy a message style web service with a message driven EJB as
    the receiver and am getting the following exception:
    <Jan 22, 2002 10:51:06 AM PST> <Warning> <EJB> <MessageDrivenBean threw an Exception
    in onMessage(). The exception was:
    java.lang.ClassCastException: weblogic.jms.common.ObjectMessageImpl
    java.lang.ClassCastException: weblogic.jms.common.ObjectMessageImpl
    at credit.message.PostDefaultPayment.onMessage(PostDefaultPayment.java:24)
    at weblogic.ejb20.internal.MDListener.execute(MDListener.java:254)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
    public void onMessage(Message message) {
    System.out.println("onMessage");
    TextMessage textmessage = (TextMessage)message. // It is throwing
    the exception on this line --looks pretty normal
    Has anyone seen this before? Am I missing something?
    Thanks,
    Tim

    Hi Tim,
    I think the problem is that you are assuming that the data type, of the message
    argument to the onMessage(Message message) method in your MDB, is of type TextMessage.
    I agree that this seems logical, especially since you passed "a string" to the
    Message-style Web Service. However, this is not the case, because the WSDL uses
    the "xsd:anyType" as the data type for any argument you pass to the send() method
    ;-) This maps to a java.lang.Object in the WebLogic Web Services implementation,
    which is why you get the casting error. Try this instead:
    public void onMessage(Message msg)
         try
              String msgText;
              ObjectMessage objMessage = (ObjectMessage)msg;
              msgText = (String)objMessage.getObject();
    System.out.println("[PostDefaultPayment.onMessage(Message)] msgText=" + msgText);
    System.out.println("[PostDefaultPayment.onMessage(Message)] msg.getJMSType()="
    + msg.getJMSType());
    System.out.println("[PostDefaultPayment.onMessage(Message)] msg.getJMSCorrelationID()="
    + msg.getJMSCorrelationID());
    System.out.println("[PostDefaultPayment.onMessage(Message)] msg.getJMSMessageID()="
    + msg.getJMSMessageID());
         catch(Exception e)
    e.printStackTrace();
    Regards,
    Mike Wooten
    "Tim Uy" <[email protected]> wrote:
    >
    Hi,
    I'm trying to deploy a message style web service with a message driven
    EJB as
    the receiver and am getting the following exception:
    <Jan 22, 2002 10:51:06 AM PST> <Warning> <EJB> <MessageDrivenBean threw
    an Exception
    in onMessage(). The exception was:
    java.lang.ClassCastException: weblogic.jms.common.ObjectMessageImpl
    java.lang.ClassCastException: weblogic.jms.common.ObjectMessageImpl
    at credit.message.PostDefaultPayment.onMessage(PostDefaultPayment.java:24)
    at weblogic.ejb20.internal.MDListener.execute(MDListener.java:254)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
    public void onMessage(Message message) {
    System.out.println("onMessage");
    TextMessage textmessage = (TextMessage)message. // It
    is throwing
    the exception on this line --looks pretty normal
    Has anyone seen this before? Am I missing something?
    Thanks,
    Tim

  • Help : Message Driven bean seeing the same message multiple times.

    ( We are using weblogic 8.1 on Solaris )
    We have a bunch of message driven beans with the transaction type as 'Container' and the acknowledge-mode mode as auto-acknowledge. They are consuming messages from a weblogic Queue ( javax.jms.Queue ). The MBD container is also weblogic 8.1.
    We have 7 instances of the bean consuming messages.
    Most of the messages are picked up and processed only once as expected.
    But randomly we are seeing that sometimes the same message is delivered again ( Message.getJmsRedelivered = true ) eventhough it was once picked up and processed successfully once.
    We are completely lost and our production machine is in big trouble as a result of this.
    ( Is it possible that weblogic uses unreliable UDP for acknowledging messages. If yes where do we change this setting )
    Any help will be greatly appreciated
    Thanks
    --sony
    ================ejb-jar.xml BEGIN
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE ejb-jar PUBLIC '-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN' 'http://java.sun.com/dtd/ejb-jar_2_0.dtd'>
    <ejb-jar>
    <enterprise-beans>
    <message-driven>
    <description>DslUpdtDdpostPrcsrMDB</description>
    <ejb-name>DslUpdtDdpostPrcsrMDB</ejb-name>
    <ejb-class>
    com.bellsouth.snt.idm.ejb.wfac.DslUpdtDdpostPrcsrMDB
    </ejb-class>
    <transaction-type>Container</transaction-type>
    <message-selector>
    <![CDATA[ idm_state = 'dsl_updt_dd_post' ]]>
    </message-selector>
    <acknowledge-mode>auto-acknowledge</acknowledge-mode>
    <message-driven-destination>
    <destination-type>javax.jms.Queue</destination-type>
    </message-driven-destination>
    <env-entry>
              <env-entry-name>MDB_NAME</env-entry-name>
              <env-entry-type>java.lang.String</env-entry-type>
              <env-entry-value>dsl_updt_dd_post</env-entry-value>
    </env-entry>
    <!--security-identity><use-caller-identity/></security-identity-->
    <resource-ref>
    <res-ref-name>jms/QueueConnectionFactory</res-ref-name>
    <res-type>javax.jms.QueueConnectionFactory</res-type>
    <res-auth>Container</res-auth>
    <res-sharing-scope>Shareable</res-sharing-scope>
    </resource-ref>
    </message-driven>
    </enterprise-beans>
    <assembly-descriptor>
    <container-transaction>
    <method>
    <ejb-name>DslUpdtDdpostPrcsrMDB</ejb-name>
    <method-name>*</method-name>
    </method>
    <trans-attribute>Required</trans-attribute>
    </container-transaction>
    </assembly-descriptor>
    </ejb-jar>
    ================ejb-jar.xml END
    ================weblogic-ejb-jar.xml BEGIN
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE weblogic-ejb-jar PUBLIC '-//BEA Systems, Inc.//DTD WebLogic 8.1.0 EJB//EN' 'http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd'>
    <weblogic-ejb-jar>
    <weblogic-enterprise-bean>
    <ejb-name>DslUpdtDdpostPrcsrMDB</ejb-name>
    <message-driven-descriptor>
    <pool>
    <max-beans-in-free-pool>10</max-beans-in-free-pool>
    <initial-beans-in-free-pool>0</initial-beans-in-free-pool>
    </pool>
    <destination-jndi-name>
    idm.jms.clip.WfacClipResponseQueue
    </destination-jndi-name>
    <connection-factory-jndi-name>
    idm.jms.IdmXaJmsQueueConnectionFactory
    </connection-factory-jndi-name>
    </message-driven-descriptor>
    <transaction-descriptor>
    <trans-timeout-seconds>
    300
    </trans-timeout-seconds>
    </transaction-descriptor>
    <reference-descriptor>
    <resource-description>
    <res-ref-name>jms/QueueConnectionFactory</res-ref-name>
    <jndi-name>idm.jms.IdmXaJmsQueueConnectionFactory</jndi-name>
    </resource-description>
    </reference-descriptor>
    <jndi-name>jms.DslUpdtDdpostPrcsrMDB</jndi-name>
    </weblogic-enterprise-bean>
    </weblogic-ejb-jar>
    ================weblogic-ejb-jar.xml END

    The transaction attribute for the MDB is set to 'Required'. Is it possible
    that your application logic may process the message successfully even in
    case of a transaction roll back? If the transaction rolls back, the message
    will be re-delivered.
    There is some docs on exactly-once processing which may help
    http://e-docs.bea.com/wls/docs81/ejb/message_beans.html#1147208
    --Sathish
    <Sony Antony> wrote in message news:[email protected]...
    ( We are using weblogic 8.1 on Solaris )
    We have a bunch of message driven beans with the transaction type as
    'Container' and the acknowledge-mode mode as auto-acknowledge. They are
    consuming messages from a weblogic Queue ( javax.jms.Queue ). The MBD
    container is also weblogic 8.1.
    We have 7 instances of the bean consuming messages.
    Most of the messages are picked up and processed only once as expected.
    But randomly we are seeing that sometimes the same message is delivered
    again ( Message.getJmsRedelivered = true ) eventhough it was once picked
    up and processed successfully once.
    We are completely lost and our production machine is in big trouble as a
    result of this.
    ( Is it possible that weblogic uses unreliable UDP for acknowledging
    messages. If yes where do we change this setting )
    Any help will be greatly appreciated
    Thanks
    --sony
    ================ejb-jar.xml BEGIN
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE ejb-jar PUBLIC '-//Sun Microsystems, Inc.//DTD Enterprise
    JavaBeans 2.0//EN' 'http://java.sun.com/dtd/ejb-jar_2_0.dtd'>
    <ejb-jar>
    <enterprise-beans>
    <message-driven>
    <description>DslUpdtDdpostPrcsrMDB</description>
    <ejb-name>DslUpdtDdpostPrcsrMDB</ejb-name>
    <ejb-class>
    com.bellsouth.snt.idm.ejb.wfac.DslUpdtDdpostPrcsrMDB
    </ejb-class>
    <transaction-type>Container</transaction-type>
    <message-selector>
    <![CDATA[ idm_state = 'dsl_updt_dd_post' ]]>
    </message-selector>
    <acknowledge-mode>auto-acknowledge</acknowledge-mode>
    <message-driven-destination>
    <destination-type>javax.jms.Queue</destination-type>
    </message-driven-destination>
    <env-entry>
    <env-entry-name>MDB_NAME</env-entry-name>
    <env-entry-type>java.lang.String</env-entry-type>
    <env-entry-value>dsl_updt_dd_post</env-entry-value>
    </env-entry>
    <!--security-identity><use-caller-identity/></security-identity-->
    <resource-ref>
    <res-ref-name>jms/QueueConnectionFactory</res-ref-name>
    <res-type>javax.jms.QueueConnectionFactory</res-type>
    <res-auth>Container</res-auth>
    <res-sharing-scope>Shareable</res-sharing-scope>
    </resource-ref>
    </message-driven>
    </enterprise-beans>
    <assembly-descriptor>
    <container-transaction>
    <method>
    <ejb-name>DslUpdtDdpostPrcsrMDB</ejb-name>
    <method-name>*</method-name>
    </method>
    <trans-attribute>Required</trans-attribute>
    </container-transaction>
    </assembly-descriptor>
    </ejb-jar>
    ================ejb-jar.xml END
    ================weblogic-ejb-jar.xml BEGIN
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE weblogic-ejb-jar PUBLIC '-//BEA Systems, Inc.//DTD WebLogic
    8.1.0 EJB//EN'
    'http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd'>
    <weblogic-ejb-jar>
    <weblogic-enterprise-bean>
    <ejb-name>DslUpdtDdpostPrcsrMDB</ejb-name>
    <message-driven-descriptor>
    <pool>
    <max-beans-in-free-pool>10</max-beans-in-free-pool>
    <initial-beans-in-free-pool>0</initial-beans-in-free-pool>
    </pool>
    <destination-jndi-name>
    idm.jms.clip.WfacClipResponseQueue
    </destination-jndi-name>
    <connection-factory-jndi-name>
    idm.jms.IdmXaJmsQueueConnectionFactory
    </connection-factory-jndi-name>
    </message-driven-descriptor>
    <transaction-descriptor>
    <trans-timeout-seconds>
    300
    </trans-timeout-seconds>
    </transaction-descriptor>
    <reference-descriptor>
    <resource-description>
    <res-ref-name>jms/QueueConnectionFactory</res-ref-name>
    <jndi-name>idm.jms.IdmXaJmsQueueConnectionFactory</jndi-name>
    </resource-description>
    </reference-descriptor>
    <jndi-name>jms.DslUpdtDdpostPrcsrMDB</jndi-name>
    </weblogic-enterprise-bean>
    </weblogic-ejb-jar>
    ================weblogic-ejb-jar.xml END

  • Message-driven bean questions

    Hello,
    i'm an Italian student trying to develop java applications in NetBeans IDE 6.1 with GlassFish V2, using Java EE 5; since I only recently approached java web programming, I have encountered some problems in using enterprise beans, especially message-driven ones: to get in touch with the stuff, I have created an enterprise application project in NetBeans with a plain message-driven bean and a servlet who sends a message to this bean, following an online netbeans tutorial.
    I'm using annotations to refer the resource in the servlet (the jms name I assigned the bean is "TestBean"):
    @Resource(mappedName="jms/TestBeanFactory")
    private ConnectionFactory connectionFactory;
    @Resource(mappedName="jms/TestBean")
    private Queue queue;I send the message by creating a connection, producing the message with a MessageProducer object, and sending it:
    Connection connection = connectionFactory.createConnection();
    Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
    MessageProducer messageProducer = session.createProducer(queue);
    TextMessage message = session.createTextMessage("This is a message.");
    messageProducer.send(message);
    messageProducer.close();
    connection.close();In the message-driven bean, I have my onMessage() method catching the message and writing to the system.out his text content:
    public void onMessage(Message message)
            TextMessage msg = null;
            try
                if (message instanceof TextMessage)
                    msg = (TextMessage) message;
                    String x = msg.getText();
                    System.out.println(x);
            catch (Exception e)
                e.printStackTrace();
                m_ctx.setRollbackOnly();
            catch (Throwable te)
                te.printStackTrace();
        }The message is sent and received, and the content printed. Ok, here are my questions:
    1) in the output window of netbeans I see the output but also an exception: "DirectConsumer:Caught Exception delivering messagecom.sun.messaging.jmq.io.Packet cannot be cast to com.sun.messaging.jms.ra.DirectPacket". What does that mean?
    2) I can't figure out how to make the bean answer this message to the servlet...and of course the servlet receive this response: in plain words, I would like to send back another message from the bean to the servlet, and process it. Can someone explain me how to do that?
    Thanks?

    1) in the output window of netbeans I see the output but also an exception: "DirectConsumer:Caught Exception delivering messagecom.sun.messaging.jmq.io.Packet cannot be cast to com.sun.messaging.jms.ra.DirectPacket". What does that mean?casting issue, but i don't know why.
    2) I can't figure out how to make the bean answer this message to the servlet...and of course the servlet receive this response: in plain words, I would like to send back another message from the bean to the servlet, and process it. Can someone explain me how to do that?a message driven bean cannot sent a response back. MDB is asynchronous. if you need to send a response back, you
    shouldn't be using an MDB. In that case, it sounds like you want a synchronous response. let a SLSB do it.
    %

  • Message Driven Bean Deployment for a JCA based inbound Connector in SAILFIN

    This post is partly related to my previous post regarding message driven bean deployment issue in SAILFIN b12 application server. I have made another post to put my question to a more specific title with some additions. I am developing a JCA based resource adapter (i.e. connector). The inbound module of the connector listens on a specific port for incoming messages from a server (EIS). The port property and the endpoint interface (custom made message driven bean interface, that is InboundListener) has been specified in the connector's deployment descriptor. When a message reaches, the connector delivers it to the a message driven bean whose code is indicated in the following:
    package com....;
    import com....ra.facade.InboundListener;
    import javax.ejb.ActivationConfigProperty;
    import javax.ejb.MessageDriven;
    import javax.jms.Message;
    import javax.jms.MessageListener;
    import java.util.logging.*;
    * Entity class InboundMessageReceiverMDB
    * @author efikayd
    @MessageDriven(
    mappedName = "InboundMessageReceiverMDB",
    messageListenerInterface = com......ra.facade.InboundListener.class,
    activationConfig = {
    @ActivationConfigProperty(
    propertyName = "listenerPort", propertyValue = "12345"),
    @ActivationConfigProperty(
    propertyName="ConnectionFactoryJndiName", propertyValue="RAjms/MyQCF"),
    @ActivationConfigProperty(
    propertyName="DestinationName", propertyValue="MyQueue"),
    @ActivationConfigProperty(
    propertyName="DestinationType", propertyValue="javax.jms.Queue")
    public class InboundMessageReceiverMDB implements InboundListener, MessageListener {
    private static final Logger logger = Logger.getLogger("com.xyz.inbound.InboundMessageReceiverMDB");
    /** Creates a new instance of InboundMessageReceiverMDB */
    public InboundMessageReceiverMDB() {
    public void onMessage(Message message) {
    public void receiveMessage(String message) {
    logger.log(Level.SEVERE, "CLASS: " + getClass().getName() + "METHOD: receiveMessage() ==> Message received...: " + message);
    The listener interface is the following:
    package com...ra.facade;
    public interface InboundListener{
    public void receiveMessage(String message);
    I have set the JMS resource and the queue properties on the admin console of the SAILFIN instance that is locally installed on my Linux machine (Suse 9 - kernel number: 2.6.5-7.244) in the following manner:
    ConnectionFactory:
    JNDI Name: RAjms/MyQCF
    Pool Name: RAjms/MyQCF
    Type: javax.jms.ConnectionFactory
    Status: enabled
    Property1 ==> Name: DestinationType Value: javax.jms.Queue
    Property2 ==> Name: DestinationName Value: MyQueue
    Destination (i.e. queue):
    JNDIName: MyQueue
    Physical Destination Name: MyQueue
    status: enabled
    Property1 ==> Name: DestinationType Value:javax.jms.Queue
    Property2 ==> Name: DestinationName Value:MyQueue
    When I first written this message driven bean, it was not implementing the MessageListener interface. It was only implementing my own InboundListener interface. I did this because JCA specification says that the endpoint (i.e. message driven bean ) is not supposed to make use of JMS and its MessageListener interface. It says it can support custom message listener interface so to say. Then I got the exceptions that are same as the exceptions stated below. So, I made the bean implement the JMS MessageListener interface in addtion to my InboundListener interface assuming that exceptions result from not including the JMS MessageListener interface. Then I generated the necessary JMS resources with configuration settings stated above in the application server. However, I am still getting the same exceptions (see below) and nothing has changed. Do you think the above configuration for the JMS resource is fine and appropriate to the activation configuration specifications in my message driven bean code? Am I missing something on this configuration? Below, I have indicated the message that I got on the linux terminal when I attempt to deploy the message driven bean and the related server log. Thank you very much in advance for your help.
    Kind regards,
    faydemir
    PS: The 'restart' command in the following linux terminal outcome basically makes a call to a bash script which deploys the message driven bean to the SAILFIN application server. The resource adapter instance is already deployed on the application server before attempting to deploy the message driven bean. I am sure that the resource adapter successfully receives the messages from the EIS but it cannot deliver them to the endpoint (i.e.the message driven bean) since the bean is unable to be deployed correctly. I am using Netbeans IDE 5.5.1
    WHILE DEPLOYING:
    ws2089 [11:29am] [home/efikayd/bin] -> ./restart
    Command deploy executed successfully with following warning messages: Error occurred during application loading phase. The application will not run properly. Please fix your application and redeploy.
    WARNING: com.sun.enterprise.deployment.backend.IASDeploymentException: Error while loading EJB module [InboundReceiverMDBModule]. Please refer to the server log for more details.
    ws2089 [11:29am] [home/efikayd/bin] ->
    SERVER LOG:
    [#|2008-01-03T11:29:00.542+0100|INFO|sun-appserver9.1|javax.enterprise.system.core|_ThreadID=10;_ThreadName=main;|Application server startup complete.|#]
    [#|2008-01-03T11:29:09.482+0100|INFO|sun-appserver9.1|javax.enterprise.system.tools.admin|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;/tmp/s1astempdomain1server-1825660455/InboundReceiverMDBModule.jar;|ADM1006:Uploading the file to:[/tmp/s1astempdomain1server-1825660455/InboundReceiverMDBModule.jar]|#]
    [#|2008-01-03T11:29:12.399+0100|INFO|sun-appserver9.1|javax.enterprise.system.tools.deployment|_ThreadID=18;_ThreadName=Thread-32;|deployed with moduleid = InboundReceiverMDBModule|#]
    [#|2008-01-03T11:29:12.739+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb.mdb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;InboundMessageReceiverMDB;com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|MDB00017: [InboundMessageReceiverMDB]: Exception in creating message-driven bean container: [com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB]|#]
    [#|2008-01-03T11:29:12.739+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb.mdb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|com.sun.enterprise.connectors.ConnectorRuntimeException
    com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.getPhysicalDestinationFromConfiguration(ActiveJmsResourceAdapter.java:1528)
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.updateMDBRuntimeInfo(ActiveJmsResourceAdapter.java:1379)
    at com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:170)
    at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:209)
    at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:280)
    at com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:537)
    at com.sun.enterprise.server.EJBModuleLoader.doLoad(EJBModuleLoader.java:171)
    at com.sun.enterprise.server.AbstractLoader.load(AbstractLoader.java:245)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:233)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:188)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:420)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1004)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:991)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:470)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:182)
    at com.sun.enterprise.admin.server.core.DeploymentNotificationHelper.multicastEvent(DeploymentNotificationHelper.java:308)
    at com.sun.enterprise.deployment.phasing.DeploymentServiceUtils.multicastEvent(DeploymentServiceUtils.java:230)
    at com.sun.enterprise.deployment.phasing.ServerDeploymentTarget.sendStartEvent(ServerDeploymentTarget.java:298)
    at com.sun.enterprise.deployment.phasing.ApplicationStartPhase.runPhase(ApplicationStartPhase.java:132)
    at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:108)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:920)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:591)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:635)
    at com.sun.enterprise.admin.mbeans.ApplicationsConfigMBean.start(ApplicationsConfigMBean.java:773)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:381)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:364)
    at com.sun.enterprise.admin.config.BaseConfigMBean.invoke(BaseConfigMBean.java:470)
    at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
    at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
    at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.util.proxy.ProxyClass.invoke(ProxyClass.java:90)
    at $Proxy1.invoke(Unknown Source)
    at com.sun.enterprise.admin.server.core.jmx.SunoneInterceptor.invoke(SunoneInterceptor.java:304)
    at com.sun.enterprise.interceptor.DynamicInterceptor.invoke(DynamicInterceptor.java:174)
    at com.sun.enterprise.admin.jmx.remote.server.callers.InvokeCaller.call(InvokeCaller.java:69)
    at com.sun.enterprise.admin.jmx.remote.server.MBeanServerRequestHandler.handle(MBeanServerRequestHandler.java:155)
    at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.processRequest(RemoteJmxConnectorServlet.java:122)
    at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.doPost(RemoteJmxConnectorServlet.java:193)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:738)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
    at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:411)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:290)
    at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
    at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:271)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.doProcess(DefaultProcessorTask.java:568)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.process(DefaultProcessorTask.java:813)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.executeProcessorTask(DefaultReadTask.java:339)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:261)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:212)
    at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:265)
    at com.sun.enterprise.web.connector.grizzly.WorkerThreadImpl.run(WorkerThreadImpl.java:116)
    |#]
    [#|2008-01-03T11:29:12.742+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|EJB5090: Exception in creating EJB container [com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB]|#]
    [#|2008-01-03T11:29:12.742+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|appId=InboundReceiverMDBModule moduleName=_home_efikayd_SAILFINB12_sailfin_domains_domain1_applications_j2ee-modules_InboundReceiverMDBModule ejbName=InboundMessageReceiverMDB|#]
    [#|2008-01-03T11:29:12.742+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.core.classloading|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|LDR5004: UnExpected error occured while creating ejb container
    com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.getPhysicalDestinationFromConfiguration(ActiveJmsResourceAdapter.java:1528)
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.updateMDBRuntimeInfo(ActiveJmsResourceAdapter.java:1379)
    at com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:170)
    at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:209)
    at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:280)
    at com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:537)
    at com.sun.enterprise.server.EJBModuleLoader.doLoad(EJBModuleLoader.java:171)
    at com.sun.enterprise.server.AbstractLoader.load(AbstractLoader.java:245)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:233)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:188)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:420)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1004)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:991)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:470)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:182)
    at com.sun.enterprise.admin.server.core.DeploymentNotificationHelper.multicastEvent(DeploymentNotificationHelper.java:308)
    at com.sun.enterprise.deployment.phasing.DeploymentServiceUtils.multicastEvent(DeploymentServiceUtils.java:230)
    at com.sun.enterprise.deployment.phasing.ServerDeploymentTarget.sendStartEvent(ServerDeploymentTarget.java:298)
    at com.sun.enterprise.deployment.phasing.ApplicationStartPhase.runPhase(ApplicationStartPhase.java:132)
    at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:108)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:920)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:591)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:635)
    at com.sun.enterprise.admin.mbeans.ApplicationsConfigMBean.start(ApplicationsConfigMBean.java:773)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:381)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:364)
    at com.sun.enterprise.admin.config.BaseConfigMBean.invoke(BaseConfigMBean.java:470)
    at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
    at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
    at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.util.proxy.ProxyClass.invoke(ProxyClass.java:90)
    at $Proxy1.invoke(Unknown Source)
    at com.sun.enterprise.admin.server.core.jmx.SunoneInterceptor.invoke(SunoneInterceptor.java:304)
    at com.sun.enterprise.interceptor.DynamicInterceptor.invoke(DynamicInterceptor.java:174)
    at com.sun.enterprise.admin.jmx.remote.server.callers.InvokeCaller.call(InvokeCaller.java:69)
    at com.sun.enterprise.admin.jmx.remote.server.MBeanServerRequestHandler.handle(MBeanServerRequestHandler.java:155)
    at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.processRequest(RemoteJmxConnectorServlet.java:122)
    at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.doPost(RemoteJmxConnectorServlet.java:193)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:738)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
    at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:411)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:290)
    at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
    at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:271)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.doProcess(DefaultProcessorTask.java:568)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.process(DefaultProcessorTask.java:813)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.executeProcessorTask(DefaultReadTask.java:339)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:261)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:212)
    at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:265)
    at com.sun.enterprise.web.connector.grizzly.WorkerThreadImpl.run(WorkerThreadImpl.java:116)
    |#]
    [#|2008-01-03T11:29:12.745+0100|WARNING|sun-appserver9.1|javax.enterprise.system.core|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|CORE5020: Error while loading ejb module|#]
    [#|2008-01-03T11:29:12.747+0100|WARNING|sun-appserver9.1|javax.enterprise.system.tools.admin|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;Error while loading EJB module [InboundReceiverMDBModule]. Please refer to the server log for more details. ;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|ADM1075:Error on listening event:[Error while loading EJB module [InboundReceiverMDBModule]. Please refer to the server log for more details. ]|#]

    This post is partly related to my previous post regarding message driven bean deployment issue in SAILFIN b12 application server. I have made another post to put my question to a more specific title with some additions. I am developing a JCA based resource adapter (i.e. connector). The inbound module of the connector listens on a specific port for incoming messages from a server (EIS). The port property and the endpoint interface (custom made message driven bean interface, that is InboundListener) has been specified in the connector's deployment descriptor. When a message reaches, the connector delivers it to the a message driven bean whose code is indicated in the following:
    package com....;
    import com....ra.facade.InboundListener;
    import javax.ejb.ActivationConfigProperty;
    import javax.ejb.MessageDriven;
    import javax.jms.Message;
    import javax.jms.MessageListener;
    import java.util.logging.*;
    * Entity class InboundMessageReceiverMDB
    * @author efikayd
    @MessageDriven(
    mappedName = "InboundMessageReceiverMDB",
    messageListenerInterface = com......ra.facade.InboundListener.class,
    activationConfig = {
    @ActivationConfigProperty(
    propertyName = "listenerPort", propertyValue = "12345"),
    @ActivationConfigProperty(
    propertyName="ConnectionFactoryJndiName", propertyValue="RAjms/MyQCF"),
    @ActivationConfigProperty(
    propertyName="DestinationName", propertyValue="MyQueue"),
    @ActivationConfigProperty(
    propertyName="DestinationType", propertyValue="javax.jms.Queue")
    public class InboundMessageReceiverMDB implements InboundListener, MessageListener {
    private static final Logger logger = Logger.getLogger("com.xyz.inbound.InboundMessageReceiverMDB");
    /** Creates a new instance of InboundMessageReceiverMDB */
    public InboundMessageReceiverMDB() {
    public void onMessage(Message message) {
    public void receiveMessage(String message) {
    logger.log(Level.SEVERE, "CLASS: " + getClass().getName() + "METHOD: receiveMessage() ==> Message received...: " + message);
    The listener interface is the following:
    package com...ra.facade;
    public interface InboundListener{
    public void receiveMessage(String message);
    I have set the JMS resource and the queue properties on the admin console of the SAILFIN instance that is locally installed on my Linux machine (Suse 9 - kernel number: 2.6.5-7.244) in the following manner:
    ConnectionFactory:
    JNDI Name: RAjms/MyQCF
    Pool Name: RAjms/MyQCF
    Type: javax.jms.ConnectionFactory
    Status: enabled
    Property1 ==> Name: DestinationType Value: javax.jms.Queue
    Property2 ==> Name: DestinationName Value: MyQueue
    Destination (i.e. queue):
    JNDIName: MyQueue
    Physical Destination Name: MyQueue
    status: enabled
    Property1 ==> Name: DestinationType Value:javax.jms.Queue
    Property2 ==> Name: DestinationName Value:MyQueue
    When I first written this message driven bean, it was not implementing the MessageListener interface. It was only implementing my own InboundListener interface. I did this because JCA specification says that the endpoint (i.e. message driven bean ) is not supposed to make use of JMS and its MessageListener interface. It says it can support custom message listener interface so to say. Then I got the exceptions that are same as the exceptions stated below. So, I made the bean implement the JMS MessageListener interface in addtion to my InboundListener interface assuming that exceptions result from not including the JMS MessageListener interface. Then I generated the necessary JMS resources with configuration settings stated above in the application server. However, I am still getting the same exceptions (see below) and nothing has changed. Do you think the above configuration for the JMS resource is fine and appropriate to the activation configuration specifications in my message driven bean code? Am I missing something on this configuration? Below, I have indicated the message that I got on the linux terminal when I attempt to deploy the message driven bean and the related server log. Thank you very much in advance for your help.
    Kind regards,
    faydemir
    PS: The 'restart' command in the following linux terminal outcome basically makes a call to a bash script which deploys the message driven bean to the SAILFIN application server. The resource adapter instance is already deployed on the application server before attempting to deploy the message driven bean. I am sure that the resource adapter successfully receives the messages from the EIS but it cannot deliver them to the endpoint (i.e.the message driven bean) since the bean is unable to be deployed correctly. I am using Netbeans IDE 5.5.1
    WHILE DEPLOYING:
    ws2089 [11:29am] [home/efikayd/bin] -> ./restart
    Command deploy executed successfully with following warning messages: Error occurred during application loading phase. The application will not run properly. Please fix your application and redeploy.
    WARNING: com.sun.enterprise.deployment.backend.IASDeploymentException: Error while loading EJB module [InboundReceiverMDBModule]. Please refer to the server log for more details.
    ws2089 [11:29am] [home/efikayd/bin] ->
    SERVER LOG:
    [#|2008-01-03T11:29:00.542+0100|INFO|sun-appserver9.1|javax.enterprise.system.core|_ThreadID=10;_ThreadName=main;|Application server startup complete.|#]
    [#|2008-01-03T11:29:09.482+0100|INFO|sun-appserver9.1|javax.enterprise.system.tools.admin|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;/tmp/s1astempdomain1server-1825660455/InboundReceiverMDBModule.jar;|ADM1006:Uploading the file to:[/tmp/s1astempdomain1server-1825660455/InboundReceiverMDBModule.jar]|#]
    [#|2008-01-03T11:29:12.399+0100|INFO|sun-appserver9.1|javax.enterprise.system.tools.deployment|_ThreadID=18;_ThreadName=Thread-32;|deployed with moduleid = InboundReceiverMDBModule|#]
    [#|2008-01-03T11:29:12.739+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb.mdb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;InboundMessageReceiverMDB;com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|MDB00017: [InboundMessageReceiverMDB]: Exception in creating message-driven bean container: [com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB]|#]
    [#|2008-01-03T11:29:12.739+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb.mdb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|com.sun.enterprise.connectors.ConnectorRuntimeException
    com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.getPhysicalDestinationFromConfiguration(ActiveJmsResourceAdapter.java:1528)
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.updateMDBRuntimeInfo(ActiveJmsResourceAdapter.java:1379)
    at com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:170)
    at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:209)
    at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:280)
    at com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:537)
    at com.sun.enterprise.server.EJBModuleLoader.doLoad(EJBModuleLoader.java:171)
    at com.sun.enterprise.server.AbstractLoader.load(AbstractLoader.java:245)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:233)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:188)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:420)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1004)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:991)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:470)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:182)
    at com.sun.enterprise.admin.server.core.DeploymentNotificationHelper.multicastEvent(DeploymentNotificationHelper.java:308)
    at com.sun.enterprise.deployment.phasing.DeploymentServiceUtils.multicastEvent(DeploymentServiceUtils.java:230)
    at com.sun.enterprise.deployment.phasing.ServerDeploymentTarget.sendStartEvent(ServerDeploymentTarget.java:298)
    at com.sun.enterprise.deployment.phasing.ApplicationStartPhase.runPhase(ApplicationStartPhase.java:132)
    at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:108)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:920)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:591)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:635)
    at com.sun.enterprise.admin.mbeans.ApplicationsConfigMBean.start(ApplicationsConfigMBean.java:773)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:381)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:364)
    at com.sun.enterprise.admin.config.BaseConfigMBean.invoke(BaseConfigMBean.java:470)
    at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
    at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
    at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.util.proxy.ProxyClass.invoke(ProxyClass.java:90)
    at $Proxy1.invoke(Unknown Source)
    at com.sun.enterprise.admin.server.core.jmx.SunoneInterceptor.invoke(SunoneInterceptor.java:304)
    at com.sun.enterprise.interceptor.DynamicInterceptor.invoke(DynamicInterceptor.java:174)
    at com.sun.enterprise.admin.jmx.remote.server.callers.InvokeCaller.call(InvokeCaller.java:69)
    at com.sun.enterprise.admin.jmx.remote.server.MBeanServerRequestHandler.handle(MBeanServerRequestHandler.java:155)
    at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.processRequest(RemoteJmxConnectorServlet.java:122)
    at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.doPost(RemoteJmxConnectorServlet.java:193)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:738)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
    at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:411)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:290)
    at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
    at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:271)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.doProcess(DefaultProcessorTask.java:568)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.process(DefaultProcessorTask.java:813)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.executeProcessorTask(DefaultReadTask.java:339)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:261)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:212)
    at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:265)
    at com.sun.enterprise.web.connector.grizzly.WorkerThreadImpl.run(WorkerThreadImpl.java:116)
    |#]
    [#|2008-01-03T11:29:12.742+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|EJB5090: Exception in creating EJB container [com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB]|#]
    [#|2008-01-03T11:29:12.742+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|appId=InboundReceiverMDBModule moduleName=_home_efikayd_SAILFINB12_sailfin_domains_domain1_applications_j2ee-modules_InboundReceiverMDBModule ejbName=InboundMessageReceiverMDB|#]
    [#|2008-01-03T11:29:12.742+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.core.classloading|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|LDR5004: UnExpected error occured while creating ejb container
    com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.getPhysicalDestinationFromConfiguration(ActiveJmsResourceAdapter.java:1528)
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.updateMDBRuntimeInfo(ActiveJmsResourceAdapter.java:1379)
    at com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:170)
    at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:209)
    at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:280)
    at com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:537)
    at com.sun.enterprise.server.EJBModuleLoader.doLoad(EJBModuleLoader.java:171)
    at com.sun.enterprise.server.AbstractLoader.load(AbstractLoader.java:245)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:233)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:188)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:420)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1004)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:991)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:470)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:182)
    at com.sun.enterprise.admin.server.core.DeploymentNotificationHelper.multicastEvent(DeploymentNotificationHelper.java:308)
    at com.sun.enterprise.deployment.phasing.DeploymentServiceUtils.multicastEvent(DeploymentServiceUtils.java:230)
    at com.sun.enterprise.deployment.phasing.ServerDeploymentTarget.sendStartEvent(ServerDeploymentTarget.java:298)
    at com.sun.enterprise.deployment.phasing.ApplicationStartPhase.runPhase(ApplicationStartPhase.java:132)
    at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:108)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:920)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:591)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:635)
    at com.sun.enterprise.admin.mbeans.ApplicationsConfigMBean.start(ApplicationsConfigMBean.java:773)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:381)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:364)
    at com.sun.enterprise.admin.config.BaseConfigMBean.invoke(BaseConfigMBean.java:470)
    at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
    at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
    at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.util.proxy.ProxyClass.invoke(ProxyClass.java:90)
    at $Proxy1.invoke(Unknown Source)
    at com.sun.enterprise.admin.server.core.jmx.SunoneInterceptor.invoke(SunoneInterceptor.java:304)
    at com.sun.enterprise.interceptor.DynamicInterceptor.invoke(DynamicInterceptor.java:174)
    at com.sun.enterprise.admin.jmx.remote.server.callers.InvokeCaller.call(InvokeCaller.java:69)
    at com.sun.enterprise.admin.jmx.remote.server.MBeanServerRequestHandler.handle(MBeanServerRequestHandler.java:155)
    at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.processRequest(RemoteJmxConnectorServlet.java:122)
    at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.doPost(RemoteJmxConnectorServlet.java:193)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:738)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
    at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:411)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:290)
    at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
    at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
    at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:271)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.doProcess(DefaultProcessorTask.java:568)
    at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.process(DefaultProcessorTask.java:813)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.executeProcessorTask(DefaultReadTask.java:339)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:261)
    at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:212)
    at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:265)
    at com.sun.enterprise.web.connector.grizzly.WorkerThreadImpl.run(WorkerThreadImpl.java:116)
    |#]
    [#|2008-01-03T11:29:12.745+0100|WARNING|sun-appserver9.1|javax.enterprise.system.core|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|CORE5020: Error while loading ejb module|#]
    [#|2008-01-03T11:29:12.747+0100|WARNING|sun-appserver9.1|javax.enterprise.system.tools.admin|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;Error while loading EJB module [InboundReceiverMDBModule]. Please refer to the server log for more details. ;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|ADM1075:Error on listening event:[Error while loading EJB module [InboundReceiverMDBModule]. Please refer to the server log for more details. ]|#]

  • Message Driven Bean deployment problem in SAILFIN b12

    Hi,
    I am a fresh learner in EJB technology and have been experiencing a deployment problem while attempting to deploy a very simple message driven bean, that does nothing basically, to a SAILFIN (b12) application server instance. I am using NetBeans 5.5.1 to form the message driven bean but I deploy the bean manually on a Linux terminal. The following is the code of the bean:
    package trial.mdb;
    import javax.annotation.Resource;
    import javax.ejb.ActivationConfigProperty;
    import javax.ejb.MessageDriven;
    import javax.jms.Message;
    import javax.jms.MessageListener;
    @MessageDriven(mappedName = "jms/MDB1", activationConfig = {
    @ActivationConfigProperty(propertyName = "acknowledgeMode", propertyValue = "Auto-acknowledge"),
    @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue")
    public class MDB1 implements MessageListener {
    /** Creates a new instance of MDB1 */
    public MDB1() {
    public void onMessage(Message message) {
    I got the following message after deployment attempt:
    "Command deploy executed successfully with following warning messages: Error occurred during application loading phase. The application will not run properly. Please fix your application and redeploy.
    WARNING: com.sun.enterprise.deployment.backend.IASDeploymentException: Error while loading EJB module [TrialMDB]. Please refer to the server log for more details."
    The verifier does not give any error, warning or failure message and it states "com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : jms/MDB1;" in the server log. Below, I have stated the content of the server log. I am novice in EJB technology particularly in message driven beans so any help will be appreciated. Thanks a lot in advance.
    --faydemir
    The content of the server log:
    [#|2008-01-02T16:25:11.106+0100|INFO|sun-appserver9.1|javax.enterprise.system.tools.avk.tools.verifier|_ThreadID=23;_ThreadName=Thread-41;|Verifying: [ _home_efikayd_SAILFINB12_sailfin_domains_domain1_applications_j2ee-modules_TrialMDB ]|#]
    [#|2008-01-02T16:25:11.286+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.tools.avk.tools.verifier|_ThreadID=23;_ThreadName=Thread-41;_RequestID=c8eac819-597f-454b-b189-1ad5a88770ac;|
    STATIC VERIFICATION RESULTS
    NUMBER OF FAILURES/WARNINGS/ERRORS
    # of Failures : 0
    # of Warnings : 0
    # of Errors : 0
    END OF STATIC VERIFICATION RESULTS
    |#]
    [#|2008-01-02T16:25:11.286+0100|INFO|sun-appserver9.1|javax.enterprise.system.tools.avk.tools.verifier|_ThreadID=23;_ThreadName=Thread-41;|No errors found in the archive.|#]
    [#|2008-01-02T16:25:11.367+0100|INFO|sun-appserver9.1|javax.enterprise.system.tools.deployment|_ThreadID=23;_ThreadName=Thread-41;|deployed with moduleid = TrialMDB|#]
    [#|2008-01-02T16:25:11.441+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb.mdb|_ThreadID=24;_ThreadName=Thread-40;MDB1;com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : jms/MDB1;_RequestID=59330d0c-6ffd-48d6-9c99-a25e98b13700;|MDB00017: [MDB1]: Exception in creating message-driven bean container: [com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : jms/MDB1]|#]
    [#|2008-01-02T16:25:11.441+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb.mdb|_ThreadID=24;_ThreadName=Thread-40;_RequestID=59330d0c-6ffd-48d6-9c99-a25e98b13700;|com.sun.enterprise.connectors.ConnectorRuntimeException
    com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : jms/MDB1
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.getPhysicalDestinationFromConfiguration(ActiveJmsResourceAdapter.java:1528)
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.updateMDBRuntimeInfo(ActiveJmsResourceAdapter.java:1379)
    at com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:170)
    at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:209)
    at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:280)
    at com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:537)
    at com.sun.enterprise.server.EJBModuleLoader.doLoad(EJBModuleLoader.java:171)
    at com.sun.enterprise.server.AbstractLoader.load(AbstractLoader.java:245)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:233)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:188)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:420)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1004)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:991)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:470)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:182)
    at com.sun.enterprise.admin.server.core.DeploymentNotificationHelper.multicastEvent(DeploymentNotificationHelper.java:308)
    at com.sun.enterprise.deployment.phasing.DeploymentServiceUtils.multicastEvent(DeploymentServiceUtils.java:230)
    at com.sun.enterprise.deployment.phasing.ServerDeploymentTarget.sendStartEvent(ServerDeploymentTarget.java:298)
    at com.sun.enterprise.deployment.phasing.ApplicationStartPhase.runPhase(ApplicationStartPhase.java:132)
    at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:108)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:920)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:591)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:635)
    at com.sun.enterprise.admin.mbeans.ApplicationsConfigMBean.start(ApplicationsConfigMBean.java:773)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:381)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:364)
    at com.sun.enterprise.admin.config.BaseConfigMBean.invoke(BaseConfigMBean.java:470)
    at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
    at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
    at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.util.proxy.ProxyClass.invoke(ProxyClass.java:90)
    at $Proxy1.invoke(Unknown Source)
    at com.sun.enterprise.admin.server.core.jmx.SunoneInterceptor.invoke(SunoneInterceptor.java:304)
    at com.sun.enterprise.interceptor.DynamicInterceptor.invoke(DynamicInterceptor.java:174)
    at com.sun.enterprise.deployment.client.DeploymentClientUtils.startApplication(DeploymentClientUtils.java:154)
    at com.sun.enterprise.deployment.client.DeployAction.run(DeployAction.java:535)
    at java.lang.Thread.run(Thread.java:619)
    |#]
    [#|2008-01-02T16:25:11.443+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb|_ThreadID=24;_ThreadName=Thread-40;com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : jms/MDB1;_RequestID=59330d0c-6ffd-48d6-9c99-a25e98b13700;|EJB5090: Exception in creating EJB container [com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : jms/MDB1]|#]
    [#|2008-01-02T16:25:11.443+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb|_ThreadID=24;_ThreadName=Thread-40;_RequestID=59330d0c-6ffd-48d6-9c99-a25e98b13700;|appId=TrialMDB moduleName=_home_efikayd_SAILFINB12_sailfin_domains_domain1_applications_j2ee-modules_TrialMDB ejbName=MDB1|#]
    [#|2008-01-02T16:25:11.443+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.core.classloading|_ThreadID=24;_ThreadName=Thread-40;_RequestID=59330d0c-6ffd-48d6-9c99-a25e98b13700;|LDR5004: UnExpected error occured while creating ejb container
    com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : jms/MDB1
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.getPhysicalDestinationFromConfiguration(ActiveJmsResourceAdapter.java:1528)
    at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.updateMDBRuntimeInfo(ActiveJmsResourceAdapter.java:1379)
    at com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:170)
    at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:209)
    at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:280)
    at com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:537)
    at com.sun.enterprise.server.EJBModuleLoader.doLoad(EJBModuleLoader.java:171)
    at com.sun.enterprise.server.AbstractLoader.load(AbstractLoader.java:245)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:233)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:188)
    at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:420)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1004)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:991)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:470)
    at com.sun.enterprise.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:182)
    at com.sun.enterprise.admin.server.core.DeploymentNotificationHelper.multicastEvent(DeploymentNotificationHelper.java:308)
    at com.sun.enterprise.deployment.phasing.DeploymentServiceUtils.multicastEvent(DeploymentServiceUtils.java:230)
    at com.sun.enterprise.deployment.phasing.ServerDeploymentTarget.sendStartEvent(ServerDeploymentTarget.java:298)
    at com.sun.enterprise.deployment.phasing.ApplicationStartPhase.runPhase(ApplicationStartPhase.java:132)
    at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:108)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:920)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:591)
    at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:635)
    at com.sun.enterprise.admin.mbeans.ApplicationsConfigMBean.start(ApplicationsConfigMBean.java:773)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:381)
    at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:364)
    at com.sun.enterprise.admin.config.BaseConfigMBean.invoke(BaseConfigMBean.java:470)
    at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
    at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
    at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.enterprise.admin.util.proxy.ProxyClass.invoke(ProxyClass.java:90)
    at $Proxy1.invoke(Unknown Source)
    at com.sun.enterprise.admin.server.core.jmx.SunoneInterceptor.invoke(SunoneInterceptor.java:304)
    at com.sun.enterprise.interceptor.DynamicInterceptor.invoke(DynamicInterceptor.java:174)
    at com.sun.enterprise.deployment.client.DeploymentClientUtils.startApplication(DeploymentClientUtils.java:154)
    at com.sun.enterprise.deployment.client.DeployAction.run(DeployAction.java:535)
    at java.lang.Thread.run(Thread.java:619)
    |#]
    [#|2008-01-02T16:25:11.445+0100|WARNING|sun-appserver9.1|javax.enterprise.system.core|_ThreadID=24;_ThreadName=Thread-40;_RequestID=59330d0c-6ffd-48d6-9c99-a25e98b13700;|CORE5020: Error while loading ejb module|#]
    [#|2008-01-02T16:25:11.446+0100|WARNING|sun-appserver9.1|javax.enterprise.system.tools.admin|_ThreadID=24;_ThreadName=Thread-40;Error while loading EJB module [TrialMDB]. Please refer to the server log for more details. ;_RequestID=59330d0c-6ffd-48d6-9c99-a25e98b13700;|ADM1075:Error on listening event:[Error while loading EJB module [TrialMDB]. Please refer to the server log for more details. ]|#]

    Hi thank you for your answer. I did not create any jms resource in the application server because my message driven bean was not implementing the MessageListener interface. Since it did not work in that way, I added the MessageListenerInterface to the bean and formed the necessary jms resources usuing the admin console of the SAILFIN but it keeps giving the same message both on the linux terminal and the server log.
    Let me explain my situation in a more detailed way. I am developing a JCA based resource adapter (i.e.) connector. The inbound module of the connector listens on a specific port for incoming messages from a server (EIS). The port property is defined in the connector's deployment descriptor. When a message reaches, the connector delivers it to the a message driven bean whose code is indicated in the following:
    package com....;
    import com....ra.facade.InboundListener;
    import javax.ejb.ActivationConfigProperty;
    import javax.ejb.MessageDriven;
    import javax.jms.Message;
    import javax.jms.MessageListener;
    import java.util.logging.*;
    * Entity class InboundMessageReceiverMDB
    * @author efikayd
    @MessageDriven(
    mappedName = "InboundMessageReceiverMDB",
    messageListenerInterface = com......ra.facade.InboundListener.class,
    activationConfig = {
    @ActivationConfigProperty(
    propertyName = "listenerPort", propertyValue = "12345"),
    @ActivationConfigProperty(
    propertyName="ConnectionFactoryJndiName", propertyValue="RAjms/MyQCF"),
    @ActivationConfigProperty(
    propertyName="DestinationName", propertyValue="MyQueue"),
    @ActivationConfigProperty(
    propertyName="DestinationType", propertyValue="javax.jms.Queue")
    public class InboundMessageReceiverMDB implements InboundListener, MessageListener {
    private static final Logger logger = Logger.getLogger("com.xyz.inbound.InboundMessageReceiverMDB");
    /** Creates a new instance of InboundMessageReceiverMDB */
    public InboundMessageReceiverMDB() {
    public void onMessage(Message message) {
    public void receiveMessage(String message) {
    logger.log(Level.SEVERE, "CLASS: " + getClass().getName() + "METHOD: receiveMessage() ==> Message received...: " + message);
    The listener interface is the following:
    package com...ra.facade;
    public interface InboundListener{
    public void receiveMessage(String message);
    I have set the JMS resource and the destination resource properties on the admin console in the following manner:
    ConnectionFactory:
    JNDI Name: RAjms/MyQCF
    Pool Name: RAjms/MyQCF
    Type: javax.jms.ConnectionFactory
    Status: enabled
    Property1 ==> Name: DestinationType Value: javax.jms.Queue
    Property2 ==> Name: DestinationName Value: MyQueue
    Destination (i.e. queue):
    JNDIName: MyQueue
    Physical Destination Name: MyQueue
    status: enabled
    Property1 ==> Name: DestinationType Value:javax.jms.Queue
    Property2 ==> Name: DestinationName Value:MyQueue
    Although I created the JMS resources as above I am getting the same problems.Do you think the above configuration is fine and appropriate to the activation configuration definitions in my message driven bean code? Am I missing something on this configuration? Below, I have indicated the message that I got on the linux terminal when I attempt to deploy the message driven bean and the related server log. They are same as what I posted before (i.e. JMS resource cannot be created...). Thank you very much in advance for your help.
    Kind regards,
    faydemir
    PS: The 'restart' command in the following linux terminal outcome basically makes a call to a bash script which deploys the message driven bean to the SAILFIN application server. The resource adapter instance is already deployed on the application server before attempting to deploy the message driven bean.
    WHILE DEPLOYING:
    ws2089 [11:29am] [home/efikayd/bin] -> ./restart
    Command deploy executed successfully with following warning messages: Error occurred during application loading phase. The application will not run properly. Please fix your application and redeploy.
    WARNING: com.sun.enterprise.deployment.backend.IASDeploymentException: Error while loading EJB module [InboundReceiverMDBModule]. Please refer to the server log for more details.
    ws2089 [11:29am] [home/efikayd/bin] ->
    SERVER LOG:
    [#|2008-01-03T11:29:00.542+0100|INFO|sun-appserver9.1|javax.enterprise.system.core|_ThreadID=10;_ThreadName=main;|Application server startup complete.|#]
    [#|2008-01-03T11:29:09.482+0100|INFO|sun-appserver9.1|javax.enterprise.system.tools.admin|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;/tmp/s1astempdomain1server-1825660455/InboundReceiverMDBModule.jar;|ADM1006:Uploading the file to:[/tmp/s1astempdomain1server-1825660455/InboundReceiverMDBModule.jar]|#]
    [#|2008-01-03T11:29:12.399+0100|INFO|sun-appserver9.1|javax.enterprise.system.tools.deployment|_ThreadID=18;_ThreadName=Thread-32;|deployed with moduleid = InboundReceiverMDBModule|#]
    [#|2008-01-03T11:29:12.739+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb.mdb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;InboundMessageReceiverMDB;com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|MDB00017: [InboundMessageReceiverMDB]: Exception in creating message-driven bean container: [com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB]|#]
    [#|2008-01-03T11:29:12.739+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb.mdb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|com.sun.enterprise.connectors.ConnectorRuntimeException
    com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB
         at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.getPhysicalDestinationFromConfiguration(ActiveJmsResourceAdapter.java:1528)
         at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.updateMDBRuntimeInfo(ActiveJmsResourceAdapter.java:1379)
         at com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:170)
         at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:209)
         at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:280)
         at com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:537)
         at com.sun.enterprise.server.EJBModuleLoader.doLoad(EJBModuleLoader.java:171)
         at com.sun.enterprise.server.AbstractLoader.load(AbstractLoader.java:245)
         at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:233)
         at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:188)
         at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:420)
         at com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1004)
         at com.sun.enterprise.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:991)
         at com.sun.enterprise.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:470)
         at com.sun.enterprise.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:182)
         at com.sun.enterprise.admin.server.core.DeploymentNotificationHelper.multicastEvent(DeploymentNotificationHelper.java:308)
         at com.sun.enterprise.deployment.phasing.DeploymentServiceUtils.multicastEvent(DeploymentServiceUtils.java:230)
         at com.sun.enterprise.deployment.phasing.ServerDeploymentTarget.sendStartEvent(ServerDeploymentTarget.java:298)
         at com.sun.enterprise.deployment.phasing.ApplicationStartPhase.runPhase(ApplicationStartPhase.java:132)
         at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:108)
         at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:920)
         at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:591)
         at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:635)
         at com.sun.enterprise.admin.mbeans.ApplicationsConfigMBean.start(ApplicationsConfigMBean.java:773)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:381)
         at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:364)
         at com.sun.enterprise.admin.config.BaseConfigMBean.invoke(BaseConfigMBean.java:470)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
         at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
         at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.sun.enterprise.admin.util.proxy.ProxyClass.invoke(ProxyClass.java:90)
         at $Proxy1.invoke(Unknown Source)
         at com.sun.enterprise.admin.server.core.jmx.SunoneInterceptor.invoke(SunoneInterceptor.java:304)
         at com.sun.enterprise.interceptor.DynamicInterceptor.invoke(DynamicInterceptor.java:174)
         at com.sun.enterprise.admin.jmx.remote.server.callers.InvokeCaller.call(InvokeCaller.java:69)
         at com.sun.enterprise.admin.jmx.remote.server.MBeanServerRequestHandler.handle(MBeanServerRequestHandler.java:155)
         at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.processRequest(RemoteJmxConnectorServlet.java:122)
         at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.doPost(RemoteJmxConnectorServlet.java:193)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:738)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
         at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:411)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:290)
         at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
         at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
         at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:271)
         at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637)
         at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.doProcess(DefaultProcessorTask.java:568)
         at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.process(DefaultProcessorTask.java:813)
         at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.executeProcessorTask(DefaultReadTask.java:339)
         at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:261)
         at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:212)
         at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:265)
         at com.sun.enterprise.web.connector.grizzly.WorkerThreadImpl.run(WorkerThreadImpl.java:116)
    |#]
    [#|2008-01-03T11:29:12.742+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|EJB5090: Exception in creating EJB container [com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB]|#]
    [#|2008-01-03T11:29:12.742+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.container.ejb|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|appId=InboundReceiverMDBModule moduleName=_home_efikayd_SAILFINB12_sailfin_domains_domain1_applications_j2ee-modules_InboundReceiverMDBModule ejbName=InboundMessageReceiverMDB|#]
    [#|2008-01-03T11:29:12.742+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.core.classloading|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|LDR5004: UnExpected error occured while creating ejb container
    com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : InboundMessageReceiverMDB
         at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.getPhysicalDestinationFromConfiguration(ActiveJmsResourceAdapter.java:1528)
         at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.updateMDBRuntimeInfo(ActiveJmsResourceAdapter.java:1379)
         at com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:170)
         at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:209)
         at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:280)
         at com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:537)
         at com.sun.enterprise.server.EJBModuleLoader.doLoad(EJBModuleLoader.java:171)
         at com.sun.enterprise.server.AbstractLoader.load(AbstractLoader.java:245)
         at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:233)
         at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:188)
         at com.sun.enterprise.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:420)
         at com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1004)
         at com.sun.enterprise.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:991)
         at com.sun.enterprise.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:470)
         at com.sun.enterprise.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:182)
         at com.sun.enterprise.admin.server.core.DeploymentNotificationHelper.multicastEvent(DeploymentNotificationHelper.java:308)
         at com.sun.enterprise.deployment.phasing.DeploymentServiceUtils.multicastEvent(DeploymentServiceUtils.java:230)
         at com.sun.enterprise.deployment.phasing.ServerDeploymentTarget.sendStartEvent(ServerDeploymentTarget.java:298)
         at com.sun.enterprise.deployment.phasing.ApplicationStartPhase.runPhase(ApplicationStartPhase.java:132)
         at com.sun.enterprise.deployment.phasing.DeploymentPhase.executePhase(DeploymentPhase.java:108)
         at com.sun.enterprise.deployment.phasing.PEDeploymentService.executePhases(PEDeploymentService.java:920)
         at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:591)
         at com.sun.enterprise.deployment.phasing.PEDeploymentService.start(PEDeploymentService.java:635)
         at com.sun.enterprise.admin.mbeans.ApplicationsConfigMBean.start(ApplicationsConfigMBean.java:773)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:381)
         at com.sun.enterprise.admin.MBeanHelper.invokeOperationInBean(MBeanHelper.java:364)
         at com.sun.enterprise.admin.config.BaseConfigMBean.invoke(BaseConfigMBean.java:470)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
         at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
         at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.sun.enterprise.admin.util.proxy.ProxyClass.invoke(ProxyClass.java:90)
         at $Proxy1.invoke(Unknown Source)
         at com.sun.enterprise.admin.server.core.jmx.SunoneInterceptor.invoke(SunoneInterceptor.java:304)
         at com.sun.enterprise.interceptor.DynamicInterceptor.invoke(DynamicInterceptor.java:174)
         at com.sun.enterprise.admin.jmx.remote.server.callers.InvokeCaller.call(InvokeCaller.java:69)
         at com.sun.enterprise.admin.jmx.remote.server.MBeanServerRequestHandler.handle(MBeanServerRequestHandler.java:155)
         at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.processRequest(RemoteJmxConnectorServlet.java:122)
         at com.sun.enterprise.admin.jmx.remote.server.servlet.RemoteJmxConnectorServlet.doPost(RemoteJmxConnectorServlet.java:193)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:738)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
         at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:411)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:290)
         at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
         at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
         at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:271)
         at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637)
         at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.doProcess(DefaultProcessorTask.java:568)
         at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.process(DefaultProcessorTask.java:813)
         at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.executeProcessorTask(DefaultReadTask.java:339)
         at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:261)
         at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:212)
         at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:265)
         at com.sun.enterprise.web.connector.grizzly.WorkerThreadImpl.run(WorkerThreadImpl.java:116)
    |#]
    [#|2008-01-03T11:29:12.745+0100|WARNING|sun-appserver9.1|javax.enterprise.system.core|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|CORE5020: Error while loading ejb module|#]
    [#|2008-01-03T11:29:12.747+0100|WARNING|sun-appserver9.1|javax.enterprise.system.tools.admin|_ThreadID=17;_ThreadName=httpWorkerThread-4848-1;Error while loading EJB module [InboundReceiverMDBModule]. Please refer to the server log for more details. ;_RequestID=feb08bff-27af-402a-9fd5-b77b8bb5f046;|ADM1075:Error on listening event:[Error while loading EJB module [InboundReceiverMDBModule]. Please refer to the server log for more details. ]|#]

  • WebLogic hangs around after shutdown process appears to complete - Message Driven Bean related

    On my current project we have some Ant scripts that automatically
    start and stop WebLogic. The stop script equates to (not exactly but
    close enough):
    java weblogic.Admin -url localhost:8001 -password password -username
    username SHUTDOWN
    WebLogic is start and shutdown for each system module. All modules
    use the exact same script for these two actions. Some of the modules
    use Message Driven Beans and consequently, since these use JMS, a
    JMSxxx.dat file is generated in the jms_store directory. As part of
    the cleanup process the jms_store directory and all files in it are to
    be deleted AFTER WebLogic shuts down.
    The shutdown process works fine in all cases where JMS is not used and
    in all cases where JMS IS used but there are NO message driven beans.
    However, when there is a message driven bean the server does not shut
    down in a timely manner, sometimes not at all (no error messages are
    produced), and the JMSxx.dat file
    remains locked. Consequently, all of the tests run via the ant script
    for modules come to a grinding halt (i.e. environment could not be
    cleaned so further tests would be skewed).
    Can anyone shed some light on a definitive order of events during
    WebLogic's shutdown process? What is the best way to test for the
    server being up? I know there is a ping utility for weblogic - should
    this be used or should a connection to a JNDI or JMS listening port do
    the trick? Any other ideas would be welcome.
    Thanks in advance,
    Mark

    On my current project we have some Ant scripts that automatically
    start and stop WebLogic. The stop script equates to (not exactly but
    close enough):
    java weblogic.Admin -url localhost:8001 -password password -username
    username SHUTDOWN
    WebLogic is start and shutdown for each system module. All modules
    use the exact same script for these two actions. Some of the modules
    use Message Driven Beans and consequently, since these use JMS, a
    JMSxxx.dat file is generated in the jms_store directory. As part of
    the cleanup process the jms_store directory and all files in it are to
    be deleted AFTER WebLogic shuts down.
    The shutdown process works fine in all cases where JMS is not used and
    in all cases where JMS IS used but there are NO message driven beans.
    However, when there is a message driven bean the server does not shut
    down in a timely manner, sometimes not at all (no error messages are
    produced), and the JMSxx.dat file
    remains locked. Consequently, all of the tests run via the ant script
    for modules come to a grinding halt (i.e. environment could not be
    cleaned so further tests would be skewed).
    Can anyone shed some light on a definitive order of events during
    WebLogic's shutdown process? What is the best way to test for the
    server being up? I know there is a ping utility for weblogic - should
    this be used or should a connection to a JNDI or JMS listening port do
    the trick? Any other ideas would be welcome.
    Thanks in advance,
    Mark

  • Jndi-name in  Message Driven Bean

    Hi
    I have successfully created the ejb jar file for deployment using sun one studio . I created the message driven bean and I right clicked on the ejb and used the customize option to set the bean properties . But my problem is that the jndi-name in the <ejb> tags takes the value jms/(ejbname) instead of jms/(queuename) . I am attaching the xml file with this . Can any one tell how to set the jndi-name to queue value using studio
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE sun-ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Sun ONE Application Server 7.0 EJB 2.0//EN" "http://www.sun.com/software/sunone/appserver/dtds/sun-ejb-jar_2_0-0.dtd">
    <sun-ejb-jar>
    <enterprise-beans>
    <name>ejb</name>
    <ejb>
    <ejb-name>Suneesh</ejb-name>
    <jndi-name>jms/Suneesh</jndi-name> <resource-ref>
    <res-ref-name>QueueConnectionFactory</res-ref-name>
    <jndi-name>jms/QueueConnectionFactory</jndi-name>
    </resource-ref>
    <resource-env-ref>
    <resource-env-ref-name>TestQueue</resource-env-ref-name>
    <jndi-name>jms/TestQueue</jndi-name>
    </resource-env-ref>
    <pass-by-reference>false</pass-by-reference>
    </ejb>
    <ejb>
    <ejb-name>Suneesh1</ejb-name>
    <jndi-name>jms/Suneesh1</jndi-name>
    <resource-ref>
    <res-ref-name>QueueConnectionFactory</res-ref-name>
    <jndi-name>jms/QueueConnectionFactory</jndi-name>
    </resource-ref>
    <resource-env-ref>
    <resource-env-ref-name>TestQueue1</resource-env-ref-name>
    <jndi-name>jms/TestQueue1</jndi-name>
    </resource-env-ref>
    <pass-by-reference>false</pass-by-reference>
    </ejb>
    </enterprise-beans>
    </sun-ejb-jar>

    Hi Bhagya,
    Thanks for your response. I think from EJB container we can call Local EJBs with the full JNDI name. The session facade bean which is being called is a remote bean. From the session facade bean I am calling a local stateless session bean for database access. I am getting the reference of the local EJB from my session facade bean with full JNDI name "java:comp/env/ejb/EJBJNDIName". It is working fine with out any problem. My servicelocator is able to provide me the reference of the local EJB from the session facade remote bean with Full JNDI name. I am only having this problem calling from the MDB. I am really not sure whether what is causing it?
    Thanks
    Amit

  • Question about message driven bean

    hello
    i can find tons of tutoriala about developing session bean and entity bean by using jdeveloper,but can't find even one article that tell me how to develop message driven bean and jms by using jdeveloper,who can help me,where can i find such tutorial?
    thank you!

    I setup breakpoints setting thru the MDB examples in j2eesdk 1.4.
    I realize that the message to the being are being process sequentially.
    Is there a way to process message in MDB concurrently?
    Thank you.

  • Can you set isolation levels of message-driven bean transactions?

    The problem: I have 3 different message-driven beans which each get a different type of message, except for a field that is common to all. That field is used as the primary key of an entity object. The message-driven beans configured to use a container managed transaction. Each message-driven bean, in processing the message, first does a lookup by primary key to see if the object associated with the key exists, and if it does not, it requests the entity's home object to create it. After that, they do further processing. The problem is that sometimes all the beans simultaneously get a message, resulting in each bean checking for the entity object at about the same time, and if they fail to find it (because none of them has created it yet), each creates an object, all with the same primary key. This is not caught until the beans start to complete their onMessage method, which I believe results in the container committing the transaction. One of the transactions will be committed successfully, while the other two will fail, get rolled back, and then be retried with the same message. The second time through, the other beans will find the entity object (since it has been created and committed) and they will complete correctly. In the end, they right thing occurs, except that there is a troubling exception or 2 in the log telling about the constraint violation (with the primary key) and the rollback. If it was just me, that would be fine, but our customer does not like to see exceptions in the log; that indicates to him that something is wrong.
    So, I am looking for someway to make sure that the actions of the message-driven beans are serialized. One suggestion from a colleague was to set the isolation level of the transactions being used by the container in processing the message-driven beans' onMessage method. However, the documentation does not mention any way to do this for a message-driven bean. Suggestions?
    Is the use of a UserTransaction a better way to do this? If I acquire a UserTransaction within the onMessage method of a message-driven bean, can I set its isolation level? How would this work? When I get a UserTransaction, does each client get a different transaction, or do they all get the same one?

    (1) The WebLogic JMS "unit-of-order" feature is a heavily adopted feature that was specifically designed to handle similar use cases - see the JMS developer guide for extensive documentation. In your use case, if "key" is used to define UOO, then there's no limit on the number of keys that can be processed concurrently, but messages for any particular key will be processed single-threaded in the order in which they were first submitted.
    Note that if you're using distributed destinations, the UOO feature is still fully supported - but the developer and/or administrator needs to decide whether to configure the destination to use "hash" or "path service" based routing (the JMS UOO edoc outlines the trade-offs).
    (2) Another alternative is to use a single MDB with max-beans-free-pool that processes all three types (as the other poster suggested). I think this assumes all MDBs run on the same JVM.
    (3) Another alternative is to use multiple queues, with a single MDB on each Q. Where some sort of hash algorithm is used to determine which Q is for the key. This approach is a "hand-coded" variant of the approach in (1) with "hash" based routing enabled...
    (4) If all MDBs actually do run in the same JVM, a third alternative is to use code the application to use a common lock to protect each key, eg, something like:
    // assume MyLock is simply a class with a "reference counter"
    // assume some global "staticHM" hash map that is all MDBs can access
    onMessage() {
    MyLock lock = null;
    key= msg.getKey();
    synchronized(staticHM) {
    lock = staticHM.get();
    if (lock = null) {
    lock = new lock();
    staticHM.put(key, new lock());
    lock.incRefCount();
    try {
    synchronized(lock) {
    // only one onMessage will be able to lock a particular key at a time
    do your work;
    } finally {
    synchronized(staticHT) {
    if (lock.defRefCount() == 0) staticHM.remove(lock);
    if (lock = null) staticHM.put(key);
    If multiple threads get a message with the same key, then only one thread at a time will work on the key.
    Hope this helps,
    Tom

Maybe you are looking for