Message Driven Bean - Configuration problem

Hi
I have created the connection factory as jms/ConnectionFactory and physical destination as PhysicalQueue and queue as jms/Queue as per
http://java.sun.com/j2ee/1.4/docs/tutorial/doc/MDB5.html#wp79772
http://java.sun.com/j2ee/1.4/docs/tutorial/doc/MDB6.html
But I am getting the following exception
[#|2005-03-10T13:36:52.970+0530|SEVERE|sun-appserver-pe8.0.0_01|javax.enterprise.system.core.classloading|_ThreadID=11;|LDR5004: UnExpected error occured while creating ejb container
javax.naming.NamingException: Message Destination Reference java:comp/env/jms/Queue has not been linked to a Message Destination
     at com.sun.enterprise.naming.NamingManagerImpl.bindObjects(NamingManagerImpl.java:450)
     at com.sun.ejb.containers.BaseContainer.setupEnvironment(BaseContainer.java:1759)
     at com.sun.ejb.containers.BaseContainer.<init>(BaseContainer.java:376)
     at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:118)
     at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:196)
     at com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:477)
     at com.sun.enterprise.server.ApplicationLoader.load(ApplicationLoader.java:125)
     at com.sun.enterprise.server.TomcatApplicationLoader.load(TomcatApplicationLoader.java:96)
     at com.sun.enterprise.server.ApplicationManager.applicationDeployed(ApplicationManager.java:205)
     at com.sun.enterprise.server.ApplicationManager.applicationDeployed(ApplicationManager.java:156)
     at com.sun.enterprise.server.ApplicationManager.applicationDeployed(ApplicationManager.java:480)
     at com.sun.enterprise.admin.event.AdminEventMulticaster.invokeApplicationDeployEventListener(AdminEventMulticaster.java:448)
     at com.sun.enterprise.admin.event.AdminEventMulticaster.handleApplicationDeployEvent(AdminEventMulticaster.java:432)
     at com.sun.enterprise.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:299)
     at com.sun.enterprise.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:107)
     at com.sun.enterprise.admin.server.core.mbean.config.ManagedServerInstance.multicastEvent(ManagedServerInstance.java:3880)
     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:324)
     at com.sun.enterprise.admin.server.core.jmx.Introspector.invokeMethodOn(Introspector.java:181)
     at com.sun.enterprise.admin.server.core.mbean.config.AdminBase.invoke(AdminBase.java:86)
     at com.sun.enterprise.admin.server.core.mbean.config.ConfigMBeanBase.invoke(ConfigMBeanBase.java:680)
     at com.sun.jmx.mbeanserver.DynamicMetaDataImpl.invoke(DynamicMetaDataImpl.java:221)
     at com.sun.jmx.mbeanserver.MetaDataImpl.invoke(MetaDataImpl.java:228)
     at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:
My ejb-jar.xml is as below
<?xml version='1.0' encoding='UTF-8'?>
<ejb-jar
xmlns="http://java.sun.com/xml/ns/j2ee"
version="2.1"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd"
>
<display-name>RegJAR</display-name>
<enterprise-beans>
<message-driven>
<ejb-name>RegistrationMDBean</ejb-name>
<ejb-class>com.registration.ejb.RegistrationMDBean</ejb-class>
<messaging-type>javax.jms.MessageListener</messaging-type>
<transaction-type>Container</transaction-type>
<message-destination-type>javax.jms.Queue</message-destination-type>
<message-destination-link>PhysicalQueue</message-destination-link>
<message-destination-ref>
<message-destination-ref-name>jms/Queue</message-destination-ref-name>
<message-destination-type>javax.jms.Queue</message-destination-type>
<message-destination-usage>Consumes</message-destination-usage>
<message-destination-link>PhysicalQueue</message-destination-link>
</message-destination-ref>
</message-driven>
</enterprise-beans>
<assembly-descriptor>
<container-transaction>
<method>
<ejb-name>RegistrationMDBean</ejb-name>
<method-name>onMessage</method-name>
<method-params>
<method-param>javax.jms.Message</method-param>
</method-params>
</method>
<trans-attribute>Required</trans-attribute>
</container-transaction>
</assembly-descriptor>
</ejb-jar>
Thanks
Suneesh

In stead of selecting the message destination I have selected the Message Dest Ref tab .But when I selected the message destination tab of JAR file I am getting the following error
[#|2005-03-10T15:51:22.263+0530|INFO|sun-appserver-pe8.0.0_01|javax.enterprise.system.tools.admin|_ThreadID=12;|ADM1041:Sent the event to instance:[ApplicationDeployEvent -- enable MDBEg]|#]
[#|2005-03-10T15:51:22.283+0530|SEVERE|sun-appserver-pe8.0.0_01|javax.enterprise.system.container.ejb.mdb|_ThreadID=12;|MDB00017: [RegistrationMDBean]: Exception in creating message-driven bean container: [com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created : ]|#]
[#|2005-03-10T15:51:22.283+0530|SEVERE|sun-appserver-pe8.0.0_01|javax.enterprise.system.container.ejb.mdb|_ThreadID=12;|com.sun.enterprise.connectors.ConnectorRuntimeException
com.sun.enterprise.connectors.ConnectorRuntimeException: JMS resource not created :
     at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.getPhysicalDestinationFromConfiguration(ActiveJmsResourceAdapter.java:296)
     at com.sun.enterprise.connectors.system.ActiveJmsResourceAdapter.updateMDBRuntimeInfo(ActiveJmsResourceAdapter.java:232)
     at com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:139)
     at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:189)
     at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:196)
     at com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:477)
     at com.sun.enterprise.server.ApplicationLoader.load(ApplicationLoader.java:125)
     at com.sun.enterprise.server.TomcatApplicationLoader.load(TomcatApplicationLoader.java:96)
     at com.sun.enterprise.server.ApplicationManager.applicationDeployed(ApplicationManager.java:205)
     at com.sun.enterprise.server.ApplicationManager.applicationDeployed(ApplicationManager.java:156)
     at com.sun.enterprise.server.ApplicationManager.applicationEnabled(ApplicationManager.java:590)
     at com.sun.enterprise.admin.event.AdminEventMulticaster.invokeApplicationDeployEventListener(AdminEventMulticaster.java:454)
     at com.sun.enterprise.admin.event.AdminEventMulticaster.handleApplicationDeployEvent(AdminEventMulticaster.java:432)
     at com.sun.enterprise.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:299)
     at com.sun.enterprise.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:107)
     at com.sun.enterprise.admin.server.core.mbean.config.ManagedServerInstance.multicastEvent(ManagedServerInstance.java:3880)
     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:324)
     at com.sun.enterprise.admin.server.core.jmx.Introspector.invokeMethodOn(Introspector.java:181)
     at com.sun.enterprise.admin.server.core.mbean.config.AdminBase.invoke(AdminBase.java:86)
     at com.sun.enterprise.admin.server.core.mbean.config.ConfigMBeanBase.invoke(ConfigMBeanBase.java:68
Thanks
Suneesh

Similar Messages

  • 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. ]|#]

  • Message Driven Bean Reference Problem

    Hi,
    I have problems a MDB referencing other beans, I am getting Class Cast
    exception whenever my MDB tries to use narrow operation after the lookup
    is done.
    The Code is as follows:
    public void ejbCreate () throws CreateException {
    log("ejbCreate called");
    try {
    InitialContext ctx = new InitialContext();
    Object ref = ctx.lookup("java:comp/env/ejb/LoggerCache");
    log("Lookup of Cache done");
    LoggerCacheHome loggerCacheHome = (LoggerCacheHome)
    PortableRemoteObject.narrow(ref, LoggerCacheHome.class);
    } catch(Exception ex) {
    ex.printStackTrace();
    The lookup is successful but when I try to use the narrow..... I get the
    following exception stackk Trace.
    Any help will be appreciated.
    TIA,
    Vikas
    Stack Trace
    java.lang.ClassCastException
    at
    weblogic.iiop.PortableRemoteObjectDelegateImpl.narrow(PortableRemoteO
    bjectDelegateImpl.java:90)
    at
    javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:137)
    at
    examples.ejb20.message.MessageTraderBean.ejbCreate(MessageTraderBean.
    java:90)
    at java.lang.reflect.Method.invoke(Native Method)
    at
    weblogic.ejb20.internal.MessageDrivenEJBHome.createBean(MessageDriven
    EJBHome.java:290)
    at
    weblogic.ejb20.pool.MessageDrivenPool.createBean(MessageDrivenPool.ja
    va:98)
    at weblogic.ejb20.pool.Pool.createInitialBeans(Pool.java:100)
    at weblogic.ejb20.pool.Pool.<init>(Pool.java:74)
    at weblogic.ejb20.pool.EntityPool.<init>(EntityPool.java:34)
    at
    weblogic.ejb20.pool.MessageDrivenPool.<init>(MessageDrivenPool.java:4
    3)
    at
    weblogic.ejb20.deployer.MessageDrivenBeanInfoImpl.getPool(MessageDriv
    enBeanInfoImpl.java:336)
    at
    weblogic.ejb20.deployer.MessageDrivenBeanInfoImpl.deploy(MessageDrive
    nBeanInfoImpl.java:403)
    at
    weblogic.ejb20.deployer.Deployer.deployDescriptor(Deployer.java:1105)
    at weblogic.ejb20.deployer.Deployer.deploy(Deployer.java:908)
    at weblogic.j2ee.EJBComponent.deploy(EJBComponent.java:31)
    at weblogic.j2ee.Application.deploy(Application.java:167)
    at
    weblogic.j2ee.J2EEService.deployApplication(J2EEService.java:173)
    at
    weblogic.management.mbeans.custom.Application.setLocalDeployed(Applic
    ation.java:217)
    at
    weblogic.management.mbeans.custom.Application.setDeployed(Application
    .java:187)
    at java.lang.reflect.Method.invoke(Native Method)
    at
    weblogic.management.internal.DynamicMBeanImpl.invokeSetter(DynamicMBe
    anImpl.java:1136)
    at
    weblogic.management.internal.DynamicMBeanImpl.setAttribute(DynamicMBe
    anImpl.java:773)
    at
    weblogic.management.internal.DynamicMBeanImpl.setAttribute(DynamicMBe
    anImpl.java:750)
    at
    weblogic.management.internal.ConfigurationMBeanImpl.setAttribute(Conf
    igurationMBeanImpl.java:256)
    at
    com.sun.management.jmx.MBeanServerImpl.setAttribute(MBeanServerImpl.j
    ava:1356)
    at
    com.sun.management.jmx.MBeanServerImpl.setAttribute(MBeanServerImpl.j
    ava:1331)
    at
    weblogic.management.internal.ConfigurationMBeanImpl.updateConfigMBean
    s(ConfigurationMBeanImpl.java:318)
    at
    weblogic.management.internal.ConfigurationMBeanImpl.setAttribute(Conf
    igurationMBeanImpl.java:259)
    at
    com.sun.management.jmx.MBeanServerImpl.setAttribute(MBeanServerImpl.j
    ava:1356)
    at
    com.sun.management.jmx.MBeanServerImpl.setAttribute(MBeanServerImpl.j
    ava:1331)
    at
    weblogic.management.internal.MBeanProxy.setAttribute(MBeanProxy.java:
    291)
    at
    weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:173)
    at $Proxy91.setDeployed(Unknown Source)
    at
    weblogic.management.mbeans.custom.ApplicationManager.autoDeploy(Appli
    cationManager.java:494)
    at
    weblogic.management.mbeans.custom.ApplicationManager.poll(Application
    Manager.java:465)
    at
    weblogic.management.mbeans.custom.ApplicationManager.poll(Application
    Manager.java:380)
    at
    weblogic.management.mbeans.custom.ApplicationManager.update(Applicati
    onManager.java:152)
    at java.lang.reflect.Method.invoke(Native Method)
    at
    weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
    eanImpl.java:562)
    at
    weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
    .java:548)
    at
    weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
    ionMBeanImpl.java:285)
    at
    com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
    55)
    at
    com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
    23)
    at
    weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:437)
    at
    weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:178)
    at $Proxy2.update(Unknown Source)
    at
    weblogic.management.console.pages._domain._upload_app._jspService(_up
    load_app.java:172)
    at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
    at
    weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubIm
    pl.java:213)
    at
    weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppSe
    rvletContext.java:1265)
    at
    weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestIm
    pl.java:1622)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)

    Print the class info for the castee and the cast-to classes. They are
    incompatible, and hence the exception. It could be a bug in your code, or
    it could be a classloader issue (resulting from how you
    packaged/deployed/how your app works) or something like that.
    Peace,
    Cameron Purdy
    Tangosol, Inc.
    http://www.tangosol.com
    +1.617.623.5782
    WebLogic Consulting Available
    "Vikas" <[email protected]> wrote in message
    news:[email protected]...
    Hi,
    I have problems a MDB referencing other beans, I am getting Class Cast
    exception whenever my MDB tries to use narrow operation after the lookup
    is done.
    The Code is as follows:
    public void ejbCreate () throws CreateException {
    log("ejbCreate called");
    try {
    InitialContext ctx = new InitialContext();
    Object ref = ctx.lookup("java:comp/env/ejb/LoggerCache");
    log("Lookup of Cache done");
    LoggerCacheHome loggerCacheHome = (LoggerCacheHome)
    PortableRemoteObject.narrow(ref, LoggerCacheHome.class);
    } catch(Exception ex) {
    ex.printStackTrace();
    The lookup is successful but when I try to use the narrow..... I get the
    following exception stackk Trace.
    Any help will be appreciated.
    TIA,
    Vikas
    Stack Trace
    java.lang.ClassCastException
    at
    weblogic.iiop.PortableRemoteObjectDelegateImpl.narrow(PortableRemoteO
    bjectDelegateImpl.java:90)
    at
    javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:137)
    at
    examples.ejb20.message.MessageTraderBean.ejbCreate(MessageTraderBean.
    java:90)
    at java.lang.reflect.Method.invoke(Native Method)
    at
    weblogic.ejb20.internal.MessageDrivenEJBHome.createBean(MessageDriven
    EJBHome.java:290)
    at
    weblogic.ejb20.pool.MessageDrivenPool.createBean(MessageDrivenPool.ja
    va:98)
    at weblogic.ejb20.pool.Pool.createInitialBeans(Pool.java:100)
    at weblogic.ejb20.pool.Pool.<init>(Pool.java:74)
    at weblogic.ejb20.pool.EntityPool.<init>(EntityPool.java:34)
    at
    weblogic.ejb20.pool.MessageDrivenPool.<init>(MessageDrivenPool.java:4
    3)
    at
    weblogic.ejb20.deployer.MessageDrivenBeanInfoImpl.getPool(MessageDriv
    enBeanInfoImpl.java:336)
    at
    weblogic.ejb20.deployer.MessageDrivenBeanInfoImpl.deploy(MessageDrive
    nBeanInfoImpl.java:403)
    at
    weblogic.ejb20.deployer.Deployer.deployDescriptor(Deployer.java:1105)
    at weblogic.ejb20.deployer.Deployer.deploy(Deployer.java:908)
    at weblogic.j2ee.EJBComponent.deploy(EJBComponent.java:31)
    at weblogic.j2ee.Application.deploy(Application.java:167)
    at
    weblogic.j2ee.J2EEService.deployApplication(J2EEService.java:173)
    at
    weblogic.management.mbeans.custom.Application.setLocalDeployed(Applic
    ation.java:217)
    at
    weblogic.management.mbeans.custom.Application.setDeployed(Application
    .java:187)
    at java.lang.reflect.Method.invoke(Native Method)
    at
    weblogic.management.internal.DynamicMBeanImpl.invokeSetter(DynamicMBe
    anImpl.java:1136)
    at
    weblogic.management.internal.DynamicMBeanImpl.setAttribute(DynamicMBe
    anImpl.java:773)
    at
    weblogic.management.internal.DynamicMBeanImpl.setAttribute(DynamicMBe
    anImpl.java:750)
    at
    weblogic.management.internal.ConfigurationMBeanImpl.setAttribute(Conf
    igurationMBeanImpl.java:256)
    at
    com.sun.management.jmx.MBeanServerImpl.setAttribute(MBeanServerImpl.j
    ava:1356)
    at
    com.sun.management.jmx.MBeanServerImpl.setAttribute(MBeanServerImpl.j
    ava:1331)
    at
    weblogic.management.internal.ConfigurationMBeanImpl.updateConfigMBean
    s(ConfigurationMBeanImpl.java:318)
    at
    weblogic.management.internal.ConfigurationMBeanImpl.setAttribute(Conf
    igurationMBeanImpl.java:259)
    at
    com.sun.management.jmx.MBeanServerImpl.setAttribute(MBeanServerImpl.j
    ava:1356)
    at
    com.sun.management.jmx.MBeanServerImpl.setAttribute(MBeanServerImpl.j
    ava:1331)
    at
    weblogic.management.internal.MBeanProxy.setAttribute(MBeanProxy.java:
    291)
    at
    weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:173)
    at $Proxy91.setDeployed(Unknown Source)
    at
    weblogic.management.mbeans.custom.ApplicationManager.autoDeploy(Appli
    cationManager.java:494)
    at
    weblogic.management.mbeans.custom.ApplicationManager.poll(Application
    Manager.java:465)
    at
    weblogic.management.mbeans.custom.ApplicationManager.poll(Application
    Manager.java:380)
    at
    weblogic.management.mbeans.custom.ApplicationManager.update(Applicati
    onManager.java:152)
    at java.lang.reflect.Method.invoke(Native Method)
    at
    weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
    eanImpl.java:562)
    at
    weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
    .java:548)
    at
    weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
    ionMBeanImpl.java:285)
    at
    com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
    55)
    at
    com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
    23)
    at
    weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:437)
    at
    weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:178)
    at $Proxy2.update(Unknown Source)
    at
    weblogic.management.console.pages._domain._upload_app._jspService(_up
    load_app.java:172)
    at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
    at
    weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubIm
    pl.java:213)
    at
    weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppSe
    rvletContext.java:1265)
    at
    weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestIm
    pl.java:1622)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)

  • 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

  • JBoss message driven bean calling a session bean

    Hi guys, can you please help me? I want my mdb to call my session bean....can you provide me some examples of ejb-jar.xml and jboss.xml with regards to this configuration....thanks...im creating my deployment descriptors manually

    Here is a little example, I hope it will help you.
    ejb-jar.xml
    =============================================
    <?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>
    <!-- Session Beans -->
    <session >
    <display-name>TestSessionEJB</display-name>
    <ejb-name>TestSession</ejb-name>
    <home>mdbtest.interfaces.TestSessionHome</home>
    <remote>mdbtest.interfaces.TestSession</remote>
    <local-home>mdbtest.interfaces.TestSessionLocalHome</local-home>
    <local>mdbtest.interfaces.TestSessionLocal</local>
    <ejb-class>mdbtest.session.TestSessionEJB</ejb-class>
    <session-type>Stateless</session-type>
    <transaction-type>Container</transaction-type>
    ... </session>
    <!-- Message Driven Beans -->
    <message-driven >
    <description><![CDATA[]]></description>
    <display-name>TestMessageEJB</display-name>
    <ejb-name>TestMessage</ejb-name>
    <ejb-class>mdbtest.message.TestMessageEJB</ejb-class>
    <transaction-type>Container</transaction-type>
    <message-selector></message-selector>
    <acknowledge-mode>Auto-acknowledge</acknowledge-mode>
    <message-driven-destination>
    <destination-type>javax.jms.Queue</destination-type>
    <subscription-durability>NonDurable</subscription-durability>
    </message-driven-destination>
    <ejb-local-ref >
    <ejb-ref-name>ejb/TestEjb</ejb-ref-name>
    <ejb-ref-type>Session</ejb-ref-type>
    <local-home>mdbtest.interfaces.TestSessionLocalHome</local-home>
    <local>mdbtest.interfaces.TestSessionLocal</local>
    <ejb-link>TestSession</ejb-link>
    </ejb-local-ref>
    </message-driven>
    </enterprise-beans>
    </ejb-jar>
    jboss.xml:
    =============================================
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE jboss PUBLIC "-//JBoss//DTD JBOSS 3.0//EN" "http://www.jboss.org/j2ee/dtd/jboss_3_0.dtd">
    <jboss>
    <enterprise-beans>
    <session>
    <ejb-name>TestSession</ejb-name>
    <jndi-name>ejb/MdbTest/TestSession</jndi-name>
    <local-jndi-name>TestSessionLocal</local-jndi-name>
    <configuration-name>Standard Stateless SessionBean</configuration-name>
    </session>
    <message-driven>
    <ejb-name>TestMessage</ejb-name>
    <destination-jndi-name>queue/MyTestQueue</destination-jndi-name>
    <configuration-name>Standard Message Driven Bean</configuration-name>
    </message-driven>
    </enterprise-beans>
    <resource-managers>
    </resource-managers>
    </jboss>

  • Message-driven bean problem (re-delivering of JMS msg)

    Sorry for crossposting this (already posted in JMS forum), but perhaps someone here (who doesn't read JMS forum) knows the answer to this problem - it's basically a JMS problem, but closely related to EJB:
    I browsed through all available docs but found no answer to this question: How can I force the re-delivery of a JMS message to happen in a few minutes instead of immediately?
    I use JMS in an EJB container (SonicQ in Borland Enterprise Server 5.0.1) and messages are consumed by a message-driven bean. The problem arises when the bean sets the transaction in which the onMessage() function is called to rollback-only: Then, the message is redelivered immediately again causing an infinte processing loop and 100% CPU load on the machine until the message is finally consumed.
    Is it possible to set a timeout for such a "temporarily rejected" message so that it is retries in a few minutes? Would that be a programming issue, or a configuration issue of the container and/or JMS?

    Hi Chranq,
    What you are talkin about is a container configuration thing as far as I can figure out. I may be that your JMS implementation doesn't support it.
    /Stig

  • Message Driven Bean: problem with @RunAs annotation

    I am having a problem using the @RunAs annotation in a message driven bean.
    I would like the code in my onMessage() method to be executed with a specific role/user, so I want to use the @RunAs annotation to achieve this.
    I am running weblogic 10.0.
    I have created the following in weblogic console:
    - Group "TestGroup"
    - User "TestUser", member of "TestGroup"
    - Global Role "TestRole", role condition: "Group : TestGroup"
    The MDB:
    package be.cegeka.test.mdb;
    import javax.annotation.Resource;
    import javax.annotation.security.RunAs;
    import javax.ejb.ActivationConfigProperty;
    import javax.ejb.MessageDriven;
    import javax.ejb.MessageDrivenContext;
    import javax.jms.Message;
    import javax.jms.MessageListener;
    @MessageDriven(
              mappedName = "testQueue",
              name = "TestMDB",
              activationConfig = {
                        @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue")
    @RunAs("TestRole")
    public class TestMDB implements MessageListener {
         @Resource
         private MessageDrivenContext mdContext;
          * {@inheritDoc}}
         public void onMessage(Message msg) {
              System.out.println("Handling message for user "
                        + mdContext.getCallerPrincipal().getName());
    }[u]The ejb-jar.xml file:
    <?xml version="1.0" encoding="UTF-8"?>
    <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
    version="3.0">
         <assembly-descriptor>
              <security-role>
                   <description>
                        Test Role.
                   </description>
                   <role-name>TestRole</role-name>
              </security-role>
         </assembly-descriptor>
    </ejb-jar>
    The weblogic-ejb-jar.xml file:
    <weblogic-ejb-jar xmlns="http://www.bea.com/ns/weblogic/10.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://www.bea.com/ns/weblogic/10.0 http://www.bea.com/ns/weblogic/10.0/weblogic-ejb-jar.xsd">
         <security-role-assignment>
              <role-name>TestRole</role-name>
              <principal-name>TestUser</principal-name>
         </security-role-assignment>
    </weblogic-ejb-jar>I would have thought that the onMessage of the MDB would print "Handling message for user TestUser", but instead it prints "Handling message for user <anonymous>".
    It seems as though the @RunAs annotation has no effect. Although I specified the role TestRole (mapped to the user TestUser), the code still seems to be executed by user anonymous.
    Am I missing something?
    Any help would be much appreciated! I've been looking at this poblem for quite a while now.

    Both beans (the MDB on WLS 10 and the session bean on WLS 8.1) use container managed transactions.
    For the MDB I do not explicitly set the transaction attributes, so it should default to container managed transactions.
    For the stateless session bean I have specified the following in the ejb-jar.xml file:
    <ejb-jar>
      <display-name>Weblogic8Service</display-name>
      <enterprise-beans>
        <session>
          <ejb-name>Weblogic8Service</ejb-name>
          <home>be.cegeka.rszv.test.session.Weblogic8ServiceRemoteHome</home>
          <remote>be.cegeka.rszv.test.session.Weblogic8ServiceRemote</remote>
          <ejb-class>be.cegeka.rszv.test.session.Weblogic8ServiceBean</ejb-class>
          <session-type>Stateless</session-type>
          <transaction-type>Container</transaction-type>
        </session>
      </enterprise-beans>
      <assembly-descriptor>
        <container-transaction>
          <method>
            <ejb-name>Weblogic8Service</ejb-name>
            <method-name>*</method-name>
          </method>
          <trans-attribute>Required</trans-attribute>
        </container-transaction>
      </assembly-descriptor>
    </ejb-jar>So as far as I understand it the transaction starts at the MDB (upon receival of a message). The transaction for the remote call to the stateless session bean (in the onMessage() of the MDB) is included in the transaction of the MDB and gets committed when the onMessage() method finishes and the transaction of the MDB itself gets committed.
    Correct me if I'm wrong here.

  • JNDI Naming Problem accessing Session Bean from Message Driven Bean

    Hi,
         I am facing a very strange problem in JNDI look up accessing a Session Bean from a Message Driven Bean. I have a session fa�ade bean(Remote Bean) which is being called from Struts Action class getting the home reference from the ServiceLocator (I have implemented ServiceLocator pattern to obtain JNDI reference for all EJBs). When I am calling the session fa�ade EJB from the Struts Action class everything is working fine.
         But when I am trying to call the same EJB from my Message Driven Bean, I am getting a JNDI exception (NameNotFoundException - No Object bound to name �java:comp/env/ejb/EJBJNDIName�). I am trying to get the remote reference from the same ServiceLocator which is successfully providing me a reference while calling from the struts action class. But the same ServiceLocator is not able to provide me a reference while calling from the Message Driven Bean. If I use the JNDI name directly like �EJBJNDIName� in the lookup it is working fine. The lookup for the name is working fine and I am able to call the Session Fa�ade bean with that reference.
         I am really not sure what exactly the problem is. If I have any problem in the ServiceLocator, it should have given me the same error while calling from Struts Action class. But it is working fine with the full name �java:comp/env/ejb/EJBJNDIName� calling from the struts action class. I am not sure whether Message Driven Bean has something to do with it. Why I am not able to get a reference of the EJB with the full name? Please Help.
    Thanks
    Amit

    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

  • Problem deploying message driven bean using Log4j

    Hello all.
    Using JDeveloper 11.1.1.0.2, I'm having a problem with a message driven bean I've created and associated with a JMS queue.
    I've created an EJB Module project in my application (in which some other projects exist), and created the bean. A simple test of the bean, sending a message through the jms queue and printing it on system.out in the mdb onMessage() worked just fine.
    However, when I add apache commons logging to my mdb, things start to go wrong. Running the project on the integrated weblogic 10.3 server just fails during deployment, due to a NoClassDefFoundError on org/apache/log4j/Logger.
    In project properties -> libraries and classpath, I've added a log4j library (Log4j-1.2.14.jar) next to Commons Logging 1.0.4 but it doesn't seem to matter anything.
    The code of my message bean:
    @MessageDriven(mappedName = "weblogic.wsee.DefaultQueue")
    public class MyMessageBean implements MessageListener {
        // logger
        private static Log sLog = LogFactory.getLog(MyMessageBean.class);
        public void ejbCreate() {
        public void ejbRemove() {
        public void onMessage(Message message) {
            MapMessage mapmsg = null;
            try {
                if (message instanceof MapMessage) {
                    mapmsg = (MapMessage)message;
                    boolean msgRedelivered = mapmsg.getJMSRedelivered();
                    String msgId = mapmsg.getJMSMessageID();
                    if (!msgRedelivered) {
                        sLog.debug("****** Successfully received message " + msgId);
                    } else {
                        sLog.debug("****** Successfully received redelivered message " + msgId);
                    // Haal de inhoud op:
                    int testInt = mapmsg.getInt("TestInt");
                    sLog.debug("TestInt:" + testInt);
                } else {
                    sLog.debug("Message of wrong type: " +
                                       message.getClass().getName());
            } catch (Exception e) {
                sLog.error("Fout in verwerken",e);           
    }Does anybody have any clue as to what I might be doing wrong or missing out here?
    The complete stacktrace:
    5-aug-2009 12:54:44 oracle.adf.share.config.ADFConfigFactory cleanUpApplicationState
    INFO: Cleaning up application state
    java.lang.ExceptionInInitializerError
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Class.java:247)
         at weblogic.ejb.container.dd.xml.EjbAnnotationProcessor.processWLSAnnotations(EjbAnnotationProcessor.java:1705)
         at weblogic.ejb.container.dd.xml.EjbDescriptorReaderImpl.processWLSAnnotations(EjbDescriptorReaderImpl.java:346)
         at weblogic.ejb.container.dd.xml.EjbDescriptorReaderImpl.createReadOnlyDescriptorFromJarFile(EjbDescriptorReaderImpl.java:192)
         at weblogic.ejb.spi.EjbDescriptorFactory.createReadOnlyDescriptorFromJarFile(EjbDescriptorFactory.java:93)
         at weblogic.ejb.container.deployer.EJBModule.loadEJBDescriptor(EJBModule.java:1198)
         at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:380)
         at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:93)
         at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:387)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:58)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:42)
         at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:615)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
         at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:191)
         at weblogic.application.internal.EarDeployment.prepare(EarDeployment.java:16)
         at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:155)
         at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:60)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.createAndPrepareContainer(ActivateOperation.java:197)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doPrepare(ActivateOperation.java:89)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.prepare(AbstractOperation.java:217)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentPrepare(DeploymentManager.java:723)
         at weblogic.deploy.internal.targetserver.DeploymentManager.prepareDeploymentList(DeploymentManager.java:1190)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handlePrepare(DeploymentManager.java:248)
         at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.prepare(DeploymentServiceDispatcher.java:159)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doPrepareCallback(DeploymentReceiverCallbackDeliverer.java:157)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$000(DeploymentReceiverCallbackDeliverer.java:12)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$1.run(DeploymentReceiverCallbackDeliverer.java:45)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:516)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: org.apache.commons.logging.LogConfigurationException: org.apache.commons.logging.LogConfigurationException: No suitable Log constructor [Ljava.lang.Class;@51b296 for org.apache.commons.logging.impl.Log4JLogger (Caused by java.lang.NoClassDefFoundError: org/apache/log4j/Logger) (Caused by org.apache.commons.logging.LogConfigurationException: No suitable Log constructor [Ljava.lang.Class;@51b296 for org.apache.commons.logging.impl.Log4JLogger (Caused by java.lang.NoClassDefFoundError: org/apache/log4j/Logger))
         at org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:543)
         at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:235)
         at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:209)
         at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:351)
         at nl.justid.dolores.mdb.MyMessageBean.<clinit>(MyMessageBean.java:19)
         ... 32 more
    Caused by: org.apache.commons.logging.LogConfigurationException: No suitable Log constructor [Ljava.lang.Class;@51b296 for org.apache.commons.logging.impl.Log4JLogger (Caused by java.lang.NoClassDefFoundError: org/apache/log4j/Logger)
         at org.apache.commons.logging.impl.LogFactoryImpl.getLogConstructor(LogFactoryImpl.java:413)
         at org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:529)
         ... 36 more
    Caused by: java.lang.NoClassDefFoundError: org/apache/log4j/Logger
         at java.lang.Class.getDeclaredConstructors0(Native Method)
         at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
         at java.lang.Class.getConstructor0(Class.java:2699)
         at java.lang.Class.getConstructor(Class.java:1657)
         at org.apache.commons.logging.impl.LogFactoryImpl.getLogConstructor(LogFactoryImpl.java:410)
         ... 37 more
    Caused by: java.lang.ClassNotFoundException: org.apache.log4j.Logger
         at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
         ... 42 more
    <5-aug-2009 12:54:44 uur CEST> <Error> <Deployer> <BEA-149265> <Failure occurred in the execution of deployment request with ID '1249469684085' for task '14'. Error is: 'weblogic.application.ModuleException: Exception preparing module: EJBModule(Dolores-MessageBeans-ejb)
    [EJB:011023]An error occurred while reading the deployment descriptor. The error was:
    null.'
    weblogic.application.ModuleException: Exception preparing module: EJBModule(Dolores-MessageBeans-ejb)
    [EJB:011023]An error occurred while reading the deployment descriptor. The error was:
    null.
         at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:452)
         at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:93)
         at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:387)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:58)
         Truncated. see log file for complete stacktrace
    java.lang.ClassNotFoundException: org.apache.log4j.Logger
         at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
         Truncated. see log file for complete stacktrace
    >
    5-aug-2009 12:54:44 oracle.adf.share.config.ADFConfigFactory cleanUpApplicationState
    INFO: Cleaning up application state
    <5-aug-2009 12:54:44 uur CEST> <Warning> <Deployer> <BEA-149004> <Failures were detected while initiating deploy task for application 'Dolores'.>
    <5-aug-2009 12:54:44 uur CEST> <Warning> <Deployer> <BEA-149078> <Stack trace for message 149004
    weblogic.application.ModuleException: Exception preparing module: EJBModule(Dolores-MessageBeans-ejb)
    [EJB:011023]An error occurred while reading the deployment descriptor. The error was:
    null.
         at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:452)
         at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:93)
         at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:387)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:58)
         Truncated. see log file for complete stacktrace
    java.lang.ClassNotFoundException: org.apache.log4j.Logger
         at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
         Truncated. see log file for complete stacktrace
    >
    [Deployer:149034]An exception occurred for task [Deployer:149026]deploy application Dolores on DefaultServer.: Exception preparing module: EJBModule(Dolores-MessageBeans-ejb)
    [EJB:011023]An error occurred while reading the deployment descriptor. The error was:
    null..
    weblogic.application.ModuleException: Exception preparing module: EJBModule(Dolores-MessageBeans-ejb)
    [EJB:011023]An error occurred while reading the deployment descriptor. The error was:
    null.
    ####  Deployment incomplete.  ####    Aug 5, 2009 12:54:44 PM
    oracle.jdeveloper.deploy.DeployException
         at oracle.jdevimpl.deploy.common.Jsr88RemoteDeployer.doDeploymentAction(Jsr88RemoteDeployer.java:247)
         at oracle.jdevimpl.deploy.common.Jsr88RemoteDeployer.deployImpl(Jsr88RemoteDeployer.java:157)
         at oracle.jdeveloper.deploy.common.AbstractDeployer.deploy(AbstractDeployer.java:94)
         at oracle.jdevimpl.deploy.fwk.WrappedDeployer.deployImpl(WrappedDeployer.java:39)
         at oracle.jdeveloper.deploy.common.AbstractDeployer.deploy(AbstractDeployer.java:94)
         at oracle.jdeveloper.deploy.common.BatchDeployer.deployImpl(BatchDeployer.java:82)
         at oracle.jdeveloper.deploy.common.AbstractDeployer.deploy(AbstractDeployer.java:94)
         at oracle.jdevimpl.deploy.fwk.WrappedDeployer.deployImpl(WrappedDeployer.java:39)
         at oracle.jdeveloper.deploy.common.AbstractDeployer.deploy(AbstractDeployer.java:94)
         at oracle.jdevimpl.deploy.fwk.DeploymentManagerImpl.deploy(DeploymentManagerImpl.java:436)
         at oracle.jdeveloper.deploy.DeploymentManager.deploy(DeploymentManager.java:209)
         at oracle.jdevimpl.runner.adrs.AdrsStarter$5$1.run(AdrsStarter.java:1365)
    Caused by: oracle.jdeveloper.deploy.DeployException
         at oracle.jdevimpl.deploy.common.Jsr88DeploymentHelper.deployApplication(Jsr88DeploymentHelper.java:413)
         at oracle.jdevimpl.deploy.common.Jsr88RemoteDeployer.doDeploymentAction(Jsr88RemoteDeployer.java:238)
         ... 11 more
    Caused by: oracle.jdeveloper.deploy.DeployException: Deployment Failed
         at oracle.jdevimpl.deploy.common.Jsr88DeploymentHelper.deployApplication(Jsr88DeploymentHelper.java:395)
         ... 12 more
    #### Cannot run application Dolores due to error deploying to DefaultServer.
    [Application Dolores stopped and undeployed from Server Instance DefaultServer]Thanks in advance!
    Greetings,
    Eelse
    Edited by: Eelse on Aug 5, 2009 1:57 PM
    Edited by: Eelse on Aug 5, 2009 5:39 PM

    Creating a new deployment profile (EAR) and including the original deployment (JAR) and the needed libraries (in a lib-directory) solved the problem.

  • My problem in Weblogic and Message Driven Bean for Topic

    Hello to all
    I used this page (http://www.ecomputercoach.com/index.php/component/content/article/90-weblogic-jms-queue-setup.html?showall=1)
    for setup JMS Server, Queue, Connection Factory on Weblogic Server
    and I created a Message Driven Bean ,I used those Queue , and all things was OK
    But I wanted to setup a Topic and use it in this manner
    I created a Topic like previous steps for setup Queue
    (http://www.ecomputercoach.com/index.php/component/content/article/90-weblogic-jms-queue-setup.html?showall=1)
    Except in Step 3  ,I selected Topic instead of Queue
    then I created a Message Driven Bean in JDeveloper , my Message Driven Bean is like this:
    @MessageDriven(mappedName = "jndi.testTopic")
    <p>
    public class aliJMS1_MessageDrivenEJBBean implements MessageListener {
        public void onMessage(Message message) {
          if(message instanceof TextMessage ){
            TextMessage txtM=(TextMessage) message;
            try{
              System.out.println(txtM.getText());
            }catch(Exception ex){
              ex.printStackTrace();
    </p>
    When I deploy the Application , Weblogic shows me this error:
    +<Aug 30, 2011 11:32:28 AM PDT> <Warning> <EJB> <BEA-010061> <The Message-Driven EJB: aliJMS1_MessageDrivenEJBBean is unable to connect to th+
    e JMS destination: jndi.testTopic. The Error was:
    +[EJB:011011]The Message-Driven EJB attempted to connect to the JMS destination with the JNDI name: jndi.testTopic. However, the object with+
    the JNDI name: jndi.testTopic is not a JMS destination, or the destination found was of the wrong type (Topic or Queue).>
    And when I send message to the topic The Message Dirven Bean dosen't work
    But when I create an ordinary Java application like this (it uses that Tpoic) :
    import java.io.*;
    import java.util.*;
    import javax.transaction.*;
    import javax.naming.*;
    import javax.jms.*;
    public class TopicReceive implements MessageListener
        public final static String JNDI_FACTORY =
            "weblogic.jndi.WLInitialContextFactory";
        public final static String JMS_FACTORY =
            "jndi.testConnectionFactory";
        public final static String TOPIC = "jndi.testTopic";
        private TopicConnectionFactory tconFactory;
        private TopicConnection tcon;
        private TopicSession tsession;
        private TopicSubscriber tsubscriber;
        private Topic topic;
        private boolean quit = false;
        public void onMessage(Message msg) {
            try {
                String msgText;
                if (msg instanceof TextMessage) {
                    msgText = ((TextMessage)msg).getText();
                } else {
                    msgText = msg.toString();
                System.out.println("JMS Message Received: " + msgText);
                if (msgText.equalsIgnoreCase("quit")) {
                    synchronized (this) {
                        quit = true;
                        this.notifyAll(); 
            } catch (JMSException jmse) {
                jmse.printStackTrace();
        public void init(Context ctx, String topicName) throws NamingException,
                                                               JMSException {
            tconFactory = (TopicConnectionFactory)ctx.lookup(JMS_FACTORY);
            tcon = tconFactory.createTopicConnection();
            tsession = tcon.createTopicSession(false, Session.AUTO_ACKNOWLEDGE);
            topic = (Topic)ctx.lookup(topicName);
            tsubscriber = tsession.createSubscriber(topic);
            tsubscriber.setMessageListener(this);
            tcon.start();
        public void close() throws JMSException {
            tsubscriber.close();
            tsession.close();
            tcon.close();
        public static void main(String[] args) throws Exception {
            InitialContext ic = getInitialContext("t3://127.0.0.1:7001");
            TopicReceive tr = new TopicReceive();
            tr.init(ic, TOPIC);
            System.out.println("JMS Ready To Receive Messages (To quit, send a \"quit\" message).");        
            synchronized (tr) {
                while (!tr.quit) {
                    try {
                        tr.wait();
                    } catch (InterruptedException ie) {
            tr.close();
        private static InitialContext getInitialContext(String url) throws NamingException {
            Hashtable env = new Hashtable();
            env.put(Context.INITIAL_CONTEXT_FACTORY, JNDI_FACTORY);
            env.put(Context.PROVIDER_URL, url);
            env.put("weblogic.jndi.createIntermediateContexts", "true");
            return new InitialContext(env);
    It's OK and shows messages When I send message to the Topic
    Now I want know why the Message Driven Bean doesn't work for those Topic
    I want create a Message Driven Bean for Topic in the same way I created for Queue
    I don't know what is problem , please advice me
    Thanks

    Could you try adding a activationconfig to the message-driven bean, for example,
    @MessageDriven(mappedName = "jndi.testTopic", activationConfig = {
            @ActivationConfigProperty(propertyName = "destinationName", propertyValue = "jndi.testTopic"),
            @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Topic")
    public class aliJMS1_MessageDrivenEJBBean implements MessageListener {
        public void onMessage(Message message) {
          if(message instanceof TextMessage ){
            TextMessage txtM=(TextMessage) message;
            try{
              System.out.println(txtM.getText());
            }catch(Exception ex){
              ex.printStackTrace();
    }

  • SAP WAS SS13 Message driven bean start up problem

    Hello,
    After we have upgraded our environment from SS9 to SS13 our app doesn't start anymore with the following exception (worked fine before):
    com.sap.engine.services.deploy.exceptions.ServerDeploymentException: Exception in operation startApp with application
    <skipped>
    Caused by: java.lang.NoSuchMethodException: com.sap.engine.services.ejb.message.SrvSessionPool.<init>(com.sap.engine.services.ejb.util.pool.PoolUser, com.sap.engine.services.ejb.Environment, java.util.Properties)
    ejb-jar.xml contains the reference to the class which couldn't be loaded:
    <property>
    <property-name>PoolClass</property-name>
    <property-value>
       com.sap.engine.services.ejb.message.SrvSessionPool
    </property-value>
    </property>
    Is there something we're missing? Please help! Thanks!
    P.S. Full stack trace below:
    Date : 09/06/2005
    Time : 18:10:13:655
    Category : /System/Audit
    Message ID : 00C09F09C00700200000000300000B8000040021B1330F51
    Severity : Error
    Location : com.sap.engine.services.deploy
    Source Name : com.sap.engine.services.deploy
    Thread : SAPEngine_System_Thread[impl:5]_62
    Message : Exception com.sap.engine.services.deploy.exceptions.ServerDeploymentException: Exception in operation startApp with application ourapp.com/App36.
         at com.sap.engine.services.deploy.server.application.ApplicationTransaction.rollbackPart(ApplicationTransaction.java:387)
         at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:301)
         at com.sap.engine.services.deploy.server.application.ParallelAdapter.makeAllPhasesImpl(ParallelAdapter.java:301)
         at com.sap.engine.services.deploy.server.application.ParallelAdapter.run(ParallelAdapter.java:73)
         at com.sap.engine.frame.core.thread.Task.run(Task.java:60)
         at com.sap.engine.core.thread.impl5.SingleThread.execute(SingleThread.java:74)
         at com.sap.engine.core.thread.impl5.SingleThread.run(SingleThread.java:140)
    Caused by: com.sap.engine.services.ejb.exceptions.deployment.EJBDeploymentException: Exception during the initialization of container boot class com.nrx.beans.job_handler.JobHandlerBean10ContainerFP.
         at com.sap.engine.services.ejb.EJBAdmin.prepareLoad(EJBAdmin.java:994)
         at com.sap.engine.services.ejb.EJBAdmin.prepareStart(EJBAdmin.java:2402)
         at com.sap.engine.services.deploy.server.application.StartTransaction.prepareCommon(StartTransaction.java:370)
         at com.sap.engine.services.deploy.server.application.StartTransaction.prepare(StartTransaction.java:318)
         at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:299)
         ... 5 more
    Caused by: com.sap.engine.services.ejb.ContainerInitializationException: Cannot initialize message system bridge com.sap.engine.services.ejb.message.JMSBridgeFP.
         at com.sap.engine.services.ejb.message.MessageContainer.load(MessageContainer.java:457)
         at com.sap.engine.services.ejb.message.MessageContainer.init(MessageContainer.java:146)
         at com.sap.engine.services.ejb.message.MessageContainerFP.init(MessageContainerFP.java:53)
         at com.sap.engine.services.ejb.EJBAdmin.prepareLoad(EJBAdmin.java:988)
         ... 9 more
    Caused by: com.sap.engine.services.ejb.message.JMSBridgeException: Cannot initialize the message-driven bean container.
         at com.sap.engine.services.ejb.message.JMSBridge.registerListener(JMSBridge.java:113)
         at com.sap.engine.services.ejb.message.MessageContainer.load(MessageContainer.java:455)
         ... 12 more
    Caused by: com.sap.engine.services.ejb.ContainerInitializationException: Cannot create a session pool for message-driven bean JobHandlerBean.
         at com.sap.engine.services.ejb.message.JMSBridge.initPool(JMSBridge.java:219)
         at com.sap.engine.services.ejb.message.JMSBridge.registerListener(JMSBridge.java:96)
         ... 13 more
    Caused by: java.lang.NoSuchMethodException: com.sap.engine.services.ejb.message.SrvSessionPool.<init>(com.sap.engine.services.ejb.util.pool.PoolUser, com.sap.engine.services.ejb.Environment, java.util.Properties)
         at java.lang.Class.getConstructor0(Class.java:1937)
         at java.lang.Class.getConstructor(Class.java:1027)
         at com.sap.engine.services.ejb.message.JMSBridge.initPool(JMSBridge.java:205)
         ... 14 more

    Hello,
    After we have upgraded our environment from SS9 to SS13 our app doesn't start anymore with the following exception (worked fine before):
    com.sap.engine.services.deploy.exceptions.ServerDeploymentException: Exception in operation startApp with application
    <skipped>
    Caused by: java.lang.NoSuchMethodException: com.sap.engine.services.ejb.message.SrvSessionPool.<init>(com.sap.engine.services.ejb.util.pool.PoolUser, com.sap.engine.services.ejb.Environment, java.util.Properties)
    ejb-jar.xml contains the reference to the class which couldn't be loaded:
    <property>
    <property-name>PoolClass</property-name>
    <property-value>
       com.sap.engine.services.ejb.message.SrvSessionPool
    </property-value>
    </property>
    Is there something we're missing? Please help! Thanks!
    P.S. Full stack trace below:
    Date : 09/06/2005
    Time : 18:10:13:655
    Category : /System/Audit
    Message ID : 00C09F09C00700200000000300000B8000040021B1330F51
    Severity : Error
    Location : com.sap.engine.services.deploy
    Source Name : com.sap.engine.services.deploy
    Thread : SAPEngine_System_Thread[impl:5]_62
    Message : Exception com.sap.engine.services.deploy.exceptions.ServerDeploymentException: Exception in operation startApp with application ourapp.com/App36.
         at com.sap.engine.services.deploy.server.application.ApplicationTransaction.rollbackPart(ApplicationTransaction.java:387)
         at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:301)
         at com.sap.engine.services.deploy.server.application.ParallelAdapter.makeAllPhasesImpl(ParallelAdapter.java:301)
         at com.sap.engine.services.deploy.server.application.ParallelAdapter.run(ParallelAdapter.java:73)
         at com.sap.engine.frame.core.thread.Task.run(Task.java:60)
         at com.sap.engine.core.thread.impl5.SingleThread.execute(SingleThread.java:74)
         at com.sap.engine.core.thread.impl5.SingleThread.run(SingleThread.java:140)
    Caused by: com.sap.engine.services.ejb.exceptions.deployment.EJBDeploymentException: Exception during the initialization of container boot class com.nrx.beans.job_handler.JobHandlerBean10ContainerFP.
         at com.sap.engine.services.ejb.EJBAdmin.prepareLoad(EJBAdmin.java:994)
         at com.sap.engine.services.ejb.EJBAdmin.prepareStart(EJBAdmin.java:2402)
         at com.sap.engine.services.deploy.server.application.StartTransaction.prepareCommon(StartTransaction.java:370)
         at com.sap.engine.services.deploy.server.application.StartTransaction.prepare(StartTransaction.java:318)
         at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:299)
         ... 5 more
    Caused by: com.sap.engine.services.ejb.ContainerInitializationException: Cannot initialize message system bridge com.sap.engine.services.ejb.message.JMSBridgeFP.
         at com.sap.engine.services.ejb.message.MessageContainer.load(MessageContainer.java:457)
         at com.sap.engine.services.ejb.message.MessageContainer.init(MessageContainer.java:146)
         at com.sap.engine.services.ejb.message.MessageContainerFP.init(MessageContainerFP.java:53)
         at com.sap.engine.services.ejb.EJBAdmin.prepareLoad(EJBAdmin.java:988)
         ... 9 more
    Caused by: com.sap.engine.services.ejb.message.JMSBridgeException: Cannot initialize the message-driven bean container.
         at com.sap.engine.services.ejb.message.JMSBridge.registerListener(JMSBridge.java:113)
         at com.sap.engine.services.ejb.message.MessageContainer.load(MessageContainer.java:455)
         ... 12 more
    Caused by: com.sap.engine.services.ejb.ContainerInitializationException: Cannot create a session pool for message-driven bean JobHandlerBean.
         at com.sap.engine.services.ejb.message.JMSBridge.initPool(JMSBridge.java:219)
         at com.sap.engine.services.ejb.message.JMSBridge.registerListener(JMSBridge.java:96)
         ... 13 more
    Caused by: java.lang.NoSuchMethodException: com.sap.engine.services.ejb.message.SrvSessionPool.<init>(com.sap.engine.services.ejb.util.pool.PoolUser, com.sap.engine.services.ejb.Environment, java.util.Properties)
         at java.lang.Class.getConstructor0(Class.java:1937)
         at java.lang.Class.getConstructor(Class.java:1027)
         at com.sap.engine.services.ejb.message.JMSBridge.initPool(JMSBridge.java:205)
         ... 14 more

  • Error during deployment of Message Driven Bean

    Environment: WLS 6.1SP3 on Win2K SP2, non-clustered.
              I am getting some error (or perhaps warning) during deployment of Message
              Driven Bean. Any one seen this before?
              This error only comes on a machine with Dual Network card.
              Thanks.
              ####<Dec 11, 2002 1:23:04 AM GMT> <Info> <EJB> <QAAPP01> <Makalu> <main>
              <system> <> <010008> <EJB Deploying file: AppRuntime.jar>
              ####<Dec 11, 2002 1:23:04 AM GMT> <Warning> <J2EE> <QAAPP01> <Makalu> <main>
              <system> <> <160007> <You are running WebLogic Server with J2EE 1.3 features
              enabled. The implementation of specific J2EE 1.3 features (EJB 2.0, JSP 1.2,
              Servlet 2.3, and J2EE Connector Architecture 1.0) in BEA WebLogic Server 6.1
              is of a non-final version of the appropriate specification. It is subject to
              change in future releases once the specification becomes finalized. This may
              cause application code developed for BEA WebLogic Server 6.1 that uses the
              new features of J2EE 1.3 to be incompatible with the J2EE 1.3 platform
              supported in future releases of BEA WebLogic Server.>
              ####<Dec 11, 2002 1:23:07 AM GMT> <Warning> <EJB> <QAAPP01> <Makalu> <main>
              <system> <> <010061> <The Message-Driven EJB: ASYNCMessageDrivenBean is
              unable to connect to the JMS destination: CQM_MessageQueue. The EJB
              container will automatically attempt to re-establish the connection with the
              JMS server. This warning may occur during WebLogic Cluster start-up if the
              JMS destination is located on another server. When the JMS server connection
              is re-established, the Message-Driven EJB will again receive JMS messages.
              The Error was:
              Unable to create a JNDI InitialContext to lookup the JMS destination. The
              error was:
              javax.naming.CommunicationException. Root exception is
              java.net.ConnectException: t3://127.0.0.1:7001: Destination unreachable;
              nested exception is:
              java.net.ConnectException: Connection refused: connect; No available router
              to destination
              at weblogic.rjvm.RJVMFinder.findOrCreate(RJVMFinder.java:155)
              at weblogic.rjvm.ServerURL.findOrCreateRJVM(ServerURL.java:207)
              at
              weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLInitialCon
              textFactoryDelegate.java:307)
              at
              weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLInitialCon
              textFactoryDelegate.java:211)
              at
              weblogic.jndi.WLInitialContextFactory.getInitialContext(WLInitialContextFact
              ory.java:149)
              at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:660)
              at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:241)
              at javax.naming.InitialContext.init(InitialContext.java:217)
              at javax.naming.InitialContext.<init>(InitialContext.java:193)
              at
              weblogic.ejb20.deployer.MessageDrivenBeanInfoImpl.getInitialContext(MessageD
              rivenBeanInfoImpl.java:641)
              at
              weblogic.ejb20.internal.JMSConnectionPoller.createJMSConnection(JMSConnectio
              nPoller.java:474)
              at
              weblogic.ejb20.internal.JMSConnectionPoller.connectToJMS(JMSConnectionPoller
              .java:418)
              at
              weblogic.ejb20.internal.JMSConnectionPoller.startJMSConnectionPolling(JMSCon
              nectionPoller.java:286)
              at
              weblogic.ejb20.deployer.MessageDrivenBeanInfoImpl.deploy(MessageDrivenBeanIn
              foImpl.java:511)
              at weblogic.ejb20.deployer.Deployer.deployDescriptor(Deployer.java:1294)
              at weblogic.ejb20.deployer.Deployer.deploy(Deployer.java:996)
              at weblogic.j2ee.EJBComponent.deploy(EJBComponent.java:31)
              at weblogic.j2ee.Application.addComponent(Application.java:170)
              at weblogic.j2ee.J2EEService.addDeployment(J2EEService.java:117)
              at
              weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(DeploymentT
              arget.java:360)
              at
              weblogic.management.mbeans.custom.DeploymentTarget.addDeployments(Deployment
              Target.java:285)
              at
              weblogic.management.mbeans.custom.DeploymentTarget.updateServerDeployments(D
              eploymentTarget.java:239)
              at
              weblogic.management.mbeans.custom.DeploymentTarget.updateDeployments(Deploym
              entTarget.java:199)
              at java.lang.reflect.Method.invoke(Native Method)
              at
              weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMBeanImpl
              .java:636)
              at
              weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl.java:6
              21)
              at
              weblogic.management.internal.ConfigurationMBeanImpl.invoke(ConfigurationMBea
              nImpl.java:360)
              at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1557)
              at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1525)
              at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:468)
              at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:209)
              at $Proxy34.updateDeployments(Unknown Source)
              at
              weblogic.management.configuration.ServerMBean_CachingStub.updateDeployments(
              ServerMBean_CachingStub.java:2977)
              at
              weblogic.management.mbeans.custom.ApplicationManager.startConfigManager(Appl
              icationManager.java:372)
              at
              weblogic.management.mbeans.custom.ApplicationManager.start(ApplicationManage
              r.java:160)
              at java.lang.reflect.Method.invoke(Native Method)
              at
              weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMBeanImpl
              .java:636)
              at
              weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl.java:6
              21)
              at
              weblogic.management.internal.ConfigurationMBeanImpl.invoke(ConfigurationMBea
              nImpl.java:360)
              at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1557)
              at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1525)
              at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:468)
              at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:209)
              at $Proxy49.start(Unknown Source)
              at
              weblogic.management.configuration.ApplicationManagerMBean_CachingStub.start(
              ApplicationManagerMBean_CachingStub.java:480)
              at weblogic.management.Admin.startApplicationManager(Admin.java:1234)
              at weblogic.management.Admin.finish(Admin.java:644)
              at weblogic.t3.srvr.T3Srvr.start(T3Srvr.java:524)
              at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:207)
              at weblogic.Server.main(Server.java:35)
              >
              ####<Dec 11, 2002 1:23:07 AM GMT> <Info> <EJB> <QAAPP01> <Makalu> <main>
              <system> <> <010009> <EJB Deployed EJB with JNDI name
              ASYNCMessageDrivenBean.>
              

    Hi Tom
              Yes we do have an URL provided in the descriptor. It's
              t3://jms.server.net:7001.
              and the jms.server.net is resolved via a hosts file in Win2K
              eg,
              192.168.100.200 jms.server.net
              You are right in saying that the loopback in a dual-net card is a problem.
              But our solution
              above solves the issue as long as your host file does not use 127.0.0.1 as
              the IP.
              We need the URL b/c depending on our client's deployment , the JMS Server
              may be remote or may be local.
              "Tom Barnes" <[email protected]> wrote in message
              news:[email protected]...
              > Hi x,
              >
              > Something to do with the loopback and dual-network cards is
              > messin' with WLS' mind. I do not know what the problem is,
              > but I can guess:
              >
              > You have specified an URL in the MDB descriptor when there
              > is no need for one. If t3://127.0.0.1:7001 is in the same
              > cluster the MDB is running in (I suspect this URL is
              > actually the same WL server), then don't specify the URL.
              > This URL is only useful for connecting an MDB to a JMS
              > server that is outside local server and outside the cluster.
              > The URL may be working on single-network card systems
              > as perhaps then WL has enough info to guess that you
              > actually mean the local WL server, and simply converts
              > the context to a local context.
              >
              > Note that the URL option in the MDB descriptor is actually
              > a WebLogic extension of J2EE.
              >
              > Tom
              >
              >
              >
              > x wrote:
              > > Environment: WLS 6.1SP3 on Win2K SP2, non-clustered.
              > >
              > > I am getting some error (or perhaps warning) during deployment of
              Message
              > > Driven Bean. Any one seen this before?
              > > This error only comes on a machine with Dual Network card.
              > >
              > > Thanks.
              > >
              > >
              > >
              > > ####<Dec 11, 2002 1:23:04 AM GMT> <Info> <EJB> <QAAPP01> <Makalu> <main>
              > > <system> <> <010008> <EJB Deploying file: AppRuntime.jar>
              > > ####<Dec 11, 2002 1:23:04 AM GMT> <Warning> <J2EE> <QAAPP01> <Makalu>
              <main>
              > > <system> <> <160007> <You are running WebLogic Server with J2EE 1.3
              features
              > > enabled. The implementation of specific J2EE 1.3 features (EJB 2.0, JSP
              1.2,
              > > Servlet 2.3, and J2EE Connector Architecture 1.0) in BEA WebLogic Server
              6.1
              > > is of a non-final version of the appropriate specification. It is
              subject to
              > > change in future releases once the specification becomes finalized. This
              may
              > > cause application code developed for BEA WebLogic Server 6.1 that uses
              the
              > > new features of J2EE 1.3 to be incompatible with the J2EE 1.3 platform
              > > supported in future releases of BEA WebLogic Server.>
              > > ####<Dec 11, 2002 1:23:07 AM GMT> <Warning> <EJB> <QAAPP01> <Makalu>
              <main>
              > > <system> <> <010061> <The Message-Driven EJB: ASYNCMessageDrivenBean is
              > > unable to connect to the JMS destination: CQM_MessageQueue. The EJB
              > > container will automatically attempt to re-establish the connection with
              the
              > > JMS server. This warning may occur during WebLogic Cluster start-up if
              the
              > > JMS destination is located on another server. When the JMS server
              connection
              > > is re-established, the Message-Driven EJB will again receive JMS
              messages.
              > > The Error was:
              > > Unable to create a JNDI InitialContext to lookup the JMS destination.
              The
              > > error was:
              > > javax.naming.CommunicationException. Root exception is
              > > java.net.ConnectException: t3://127.0.0.1:7001: Destination unreachable;
              > > nested exception is:
              > > java.net.ConnectException: Connection refused: connect; No available
              router
              > > to destination
              > > at weblogic.rjvm.RJVMFinder.findOrCreate(RJVMFinder.java:155)
              > > at weblogic.rjvm.ServerURL.findOrCreateRJVM(ServerURL.java:207)
              > > at
              > >
              weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLInitialCon
              > > textFactoryDelegate.java:307)
              > > at
              > >
              weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLInitialCon
              > > textFactoryDelegate.java:211)
              > > at
              > >
              weblogic.jndi.WLInitialContextFactory.getInitialContext(WLInitialContextFact
              > > ory.java:149)
              > > at
              javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:660)
              > > at
              javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:241)
              > > at javax.naming.InitialContext.init(InitialContext.java:217)
              > > at javax.naming.InitialContext.<init>(InitialContext.java:193)
              > > at
              > >
              weblogic.ejb20.deployer.MessageDrivenBeanInfoImpl.getInitialContext(MessageD
              > > rivenBeanInfoImpl.java:641)
              > > at
              > >
              weblogic.ejb20.internal.JMSConnectionPoller.createJMSConnection(JMSConnectio
              > > nPoller.java:474)
              > > at
              > >
              weblogic.ejb20.internal.JMSConnectionPoller.connectToJMS(JMSConnectionPoller
              > > .java:418)
              > > at
              > >
              weblogic.ejb20.internal.JMSConnectionPoller.startJMSConnectionPolling(JMSCon
              > > nectionPoller.java:286)
              > > at
              > >
              weblogic.ejb20.deployer.MessageDrivenBeanInfoImpl.deploy(MessageDrivenBeanIn
              > > foImpl.java:511)
              > > at
              weblogic.ejb20.deployer.Deployer.deployDescriptor(Deployer.java:1294)
              > > at weblogic.ejb20.deployer.Deployer.deploy(Deployer.java:996)
              > > at weblogic.j2ee.EJBComponent.deploy(EJBComponent.java:31)
              > > at weblogic.j2ee.Application.addComponent(Application.java:170)
              > > at weblogic.j2ee.J2EEService.addDeployment(J2EEService.java:117)
              > > at
              > >
              weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(DeploymentT
              > > arget.java:360)
              > > at
              > >
              weblogic.management.mbeans.custom.DeploymentTarget.addDeployments(Deployment
              > > Target.java:285)
              > > at
              > >
              weblogic.management.mbeans.custom.DeploymentTarget.updateServerDeployments(D
              > > eploymentTarget.java:239)
              > > at
              > >
              weblogic.management.mbeans.custom.DeploymentTarget.updateDeployments(Deploym
              > > entTarget.java:199)
              > > at java.lang.reflect.Method.invoke(Native Method)
              > > at
              > >
              weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMBeanImpl
              > > .java:636)
              > > at
              > >
              weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl.java:6
              > > 21)
              > > at
              > >
              weblogic.management.internal.ConfigurationMBeanImpl.invoke(ConfigurationMBea
              > > nImpl.java:360)
              > > at
              com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1557)
              > > at
              com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1525)
              > > at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:468)
              > > at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:209)
              > > at $Proxy34.updateDeployments(Unknown Source)
              > > at
              > >
              weblogic.management.configuration.ServerMBean_CachingStub.updateDeployments(
              > > ServerMBean_CachingStub.java:2977)
              > > at
              > >
              weblogic.management.mbeans.custom.ApplicationManager.startConfigManager(Appl
              > > icationManager.java:372)
              > > at
              > >
              weblogic.management.mbeans.custom.ApplicationManager.start(ApplicationManage
              > > r.java:160)
              > > at java.lang.reflect.Method.invoke(Native Method)
              > > at
              > >
              weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMBeanImpl
              > > .java:636)
              > > at
              > >
              weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl.java:6
              > > 21)
              > > at
              > >
              weblogic.management.internal.ConfigurationMBeanImpl.invoke(ConfigurationMBea
              > > nImpl.java:360)
              > > at
              com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1557)
              > > at
              com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1525)
              > > at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:468)
              > > at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:209)
              > > at $Proxy49.start(Unknown Source)
              > > at
              > >
              weblogic.management.configuration.ApplicationManagerMBean_CachingStub.start(
              > > ApplicationManagerMBean_CachingStub.java:480)
              > > at weblogic.management.Admin.startApplicationManager(Admin.java:1234)
              > > at weblogic.management.Admin.finish(Admin.java:644)
              > > at weblogic.t3.srvr.T3Srvr.start(T3Srvr.java:524)
              > > at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:207)
              > > at weblogic.Server.main(Server.java:35)
              > >
              > > ####<Dec 11, 2002 1:23:07 AM GMT> <Info> <EJB> <QAAPP01> <Makalu> <main>
              > > <system> <> <010009> <EJB Deployed EJB with JNDI name
              > > ASYNCMessageDrivenBean.>
              > >
              > >
              >
              

  • Exception in setting up message-driven bean container: [MQJMS1010: not impl

    Problem
    =======
    We are trying to configure and deploy a Message Driven
    Bean to listen on a WebSphere MQ queue, using LDAP to
    share knowledge of the Queue & Connection Factory.
    But when we start the Sun One domain we get an exception:
    javax.jms.JMSException: MQJMS1010: not implemented
    (see log file at the end of this email)
    Can anybody help please ?
    The configuration of the various components are listed
    below:
    WebSphere MQ Configuration
    ==========================
    Version 5.3
    Queue Manager
    QM_Test
    Queues
    PATH_MFP.Case.Request           
         Queue Type:     Local
    Channels
    Channel_Test               
         Channel Type:     Server Connection
         Protocol Type:     TCP/IP
    LDAP configuration
    ==================
    ldap://localhost/o=mqtest
    cn=MFP_LOCAL_Factory
    javaFactory=com.ibm.mq.jms.MQQueueConnectionFactoryFactory
    javaClassName=com.ibm.mq.jms.MQQueueConnectionFactory
    javaReferenceAddress=#3#QMGR#QM_Test
    javaReferenceAddress=#6#CHAN#Channel_Test
    javaReferenceAddress=#14#TM#SYSTEM.DEFAULT.MODEL.QUEUE
    cn=MFP_LOCAL_Case_Request_Queue
    javaFactory=com.ibm.mq.jms.MQQueueFactory
    javaClassName=com.ibm.mq.jms.MQQueue
    javaReferenceAddress=#9#QU#PATH_MFP.Case.Request
    javaReferenceAddress=#10#QMGR#QM_Test
    EJB configuration
    =================
    ejb-jar.xml
         <message-driven>
    <display-name>ServerMessageDrivenBean</display-name>
    <ejb-name>ServerMessageDrivenBean</ejb-name>
         <ejb-class>nz.co.acc.emi.server.connector.mdb.ServerMessageDrivenBean</ejb-class>
         <transaction-type>Container</transaction-type>
    <message-driven-destination>
              <destination-type>javax.jms.Queue</destination-type>
    </message-driven-destination>
         </message-driven>
    sun-ejb-jar.xml
    <ejb>
         <ejb-name>ServerMessageDrivenBean</ejb-name>
    <jndi-name>MFP_LOCAL_Case_Request_Queue</jndi-name>
         <mdb-connection-factory>
              <jndi-name>MFP_LOCAL_Factory</jndi-name>
         </mdb-connection-factory>
         </ejb>
    Sun One configuration
    =====================
    MFPProcessing: JNDI: External Resources
    MFP_LOCAL_Factory          Enabled javax.jms.QueueConnectionFactory
         JNDI Name:      MFP_LOCAL_Factory
         Resource Type:     javax.jms.QueueConnectionFactory
         JNDI Lookup:     cn=MFP_LOCAL_Factory
         Factoryclass:     com.sun.jndi.ldap.LdapCtxFactory
         Properties:
              java.naming.provider.url          ldap://localhost:389/o=mqtest
              java.naming.security.authentication     none
    MFP_LOCAL_Case_Request_Queue     Enabled javax.jms.Queue
         JNDI Name:      MFP_LOCAL_Case_Request_Queue
         Resource Type:     javax.jms.Queue
         JNDI Lookup:     cn=MFP_LOCAL_Case_Request_Queue
         Factoryclass:     com.sun.jndi.ldap.LdapCtxFactory
         Properties:
              java.naming.provider.url          ldap://localhost:389/o=mqtest
    server.xml
    <mdb-container steady-pool-size="10" pool-resize-quantity="2" max-pool-size="60" idle-timeout-in-seconds="600" monitoring-enabled="true" log-level="FINEST" />
    <jms-service port="1240" admin-user-name="admin" admin-password="admin" init-timeout-in-seconds="30" enabled="true" log-level="FINE" />
    Sun One log file
    ================
    server.log
    [01/Mar/2004:10:06:48] INFO ( 657): CORE1116: Sun ONE Application Server 7.0.0_01
    [01/Mar/2004:10:06:51] INFO ( 657): CORE5076: Using [Java HotSpot(TM) Server VM, Version 1.4.2_01] from [Sun Microsystems Inc.]
    [01/Mar/2004:10:07:09] INFO ( 657): JMS5023: JMS service successfully started. Instance Name = domain1_MFPProcessing, Home = [C:/Sun/AppServer7/imq/bin].
    [01/Mar/2004:10:07:13] INFO ( 657): JTS5014: Recoverable JTS instance, serverId = [100]
    [01/Mar/2004:10:07:14] INFO ( 657): RAR5060: Install JDBC Datasources ...
    [01/Mar/2004:10:07:14] INFO ( 657): RAR5059: Binding [JDBC DataSource Name: jdbc/MfsDataSourceJConn, Pool Name: MFSConnectionPool]
    [01/Mar/2004:10:07:15] INFO ( 657): JMS5015: Install JMS resources ...
    [01/Mar/2004:10:07:47] WARNING ( 657): [EntityContainer] Created EntityContainer....
    [01/Mar/2004:10:07:49] INFO ( 657): LDR5010: All ejb(s) of [mfs] loaded successfully!
    [01/Mar/2004:10:07:52] INFO ( 657): MDB00044: Deploying message-driven bean [emi:ServerMessageDrivenBean], consuming from [MFP_LOCAL_Case_Request_Queue]
    [01/Mar/2004:10:07:52] FINE ( 657): Messages delivery is part of a container-managed tx
    [01/Mar/2004:10:07:52] FINE ( 657): emi:ServerMessageDrivenBean:reconnect-delay-in-seconds=60, reconnect-max-retries=60, reconnect-enabled=true
    [01/Mar/2004:10:07:53] INFO ( 657): MDB00028: [emi:ServerMessageDrivenBean]: Message-driven bean container using external connection factory object: [com.ibm.mq.jms.MQQueueConnectionFactory]
    [01/Mar/2004:10:07:55] FINE ( 657): emi:ServerMessageDrivenBean: Setting message-driven bean pool max-pool-size=60, steady-pool-size=10, pool-resize-quantity=2, idle-timeout-in-seconds=600
    [01/Mar/2004:10:07:55] FINE ( 657): Initializing server session factory
    [01/Mar/2004:10:07:55] FINE ( 657): Created server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@11576d7
    [01/Mar/2004:10:07:55] FINE ( 657): Created server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@2d5534
    [01/Mar/2004:10:07:55] FINE ( 657): Created server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@34d75f
    [01/Mar/2004:10:07:55] FINE ( 657): Created server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@127d15e
    [01/Mar/2004:10:07:55] FINE ( 657): Created server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@12297d7
    [01/Mar/2004:10:07:55] FINE ( 657): Created server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@1ecfeb
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): before wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@11576d7
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): before wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@2d5534
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): before wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@34d75f
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): before wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@127d15e
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): before wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@12297d7
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): before wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@1ecfeb
    [01/Mar/2004:10:07:55] FINE ( 657): Created server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@e4776b
    [01/Mar/2004:10:07:55] FINE ( 657): Created server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@15c458c
    [01/Mar/2004:10:07:55] FINE ( 657): Created server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@da1515
    [01/Mar/2004:10:07:55] FINE ( 657): Created server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@19e3e24
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): before wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@e4776b
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): before wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@15c458c
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): before wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@da1515
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): before wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@19e3e24
    [01/Mar/2004:10:07:55] INFO ( 657): MDB0001: Create message-driven bean pool with maximum pool size [60], bean idle timeout [600] seconds
    [01/Mar/2004:10:07:55] SEVERE ( 657): MDB00030: [emi:ServerMessageDrivenBean]: Exception in setting up message-driven bean container: [MQJMS1010: not implemented]
    [01/Mar/2004:10:07:55] FINE ( 657): MDB00018: [emi:ServerMessageDrivenBean]: Closing message-driven bean container connection
    [01/Mar/2004:10:07:55] WARNING ( 657): [AbstractPool]: Cancelled pool timer task at: Mon Mar 01 10:07:55 NZDT 2004
    [01/Mar/2004:10:07:55] FINEST ( 657): Thread[main,5,main]: in cleanup() ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@11576d7
    [01/Mar/2004:10:07:55] FINE ( 657): Destroyed server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@11576d7
    [01/Mar/2004:10:07:55] FINEST ( 657): Thread[main,5,main]: in cleanup() ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@2d5534
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): after wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@2d5534
    [01/Mar/2004:10:07:55] FINE ( 657): Destroyed server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@2d5534
    [01/Mar/2004:10:07:55] FINEST ( 657): Thread[main,5,main]: in cleanup() ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@34d75f
    [01/Mar/2004:10:07:55] FINE ( 657): Destroyed server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@34d75f
    [01/Mar/2004:10:07:55] FINEST ( 657): Thread[main,5,main]: in cleanup() ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@127d15e
    [01/Mar/2004:10:07:55] FINE ( 657): Destroyed server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@127d15e
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): after wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@127d15e
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): after wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@11576d7
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): after wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@34d75f
    [01/Mar/2004:10:07:55] FINEST ( 657): Thread[main,5,main]: in cleanup() ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@12297d7
    [01/Mar/2004:10:07:55] FINE ( 657): Destroyed server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@12297d7
    [01/Mar/2004:10:07:55] FINEST ( 657): Thread[main,5,main]: in cleanup() ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@1ecfeb
    [01/Mar/2004:10:07:55] FINE ( 657): Destroyed server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@1ecfeb
    [01/Mar/2004:10:07:55] FINEST ( 657): Thread[main,5,main]: in cleanup() ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@e4776b
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): after wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@e4776b
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): after wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@12297d7
    [01/Mar/2004:10:07:55] FINE ( 657): Destroyed server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@e4776b
    [01/Mar/2004:10:07:55] FINEST ( 657): Thread[main,5,main]: in cleanup() ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@15c458c
    [01/Mar/2004:10:07:55] FINE ( 657): Destroyed server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@15c458c
    [01/Mar/2004:10:07:55] FINEST ( 657): Thread[main,5,main]: in cleanup() ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@da1515
    [01/Mar/2004:10:07:55] FINE ( 657): Destroyed server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@da1515
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): after wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@1ecfeb
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): after wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@15c458c
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): after wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@da1515
    [01/Mar/2004:10:07:55] FINEST ( 657): Thread[main,5,main]: in cleanup() ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@19e3e24
    [01/Mar/2004:10:07:55] FINE ( 657): Destroyed server session: com.iplanet.ias.ejb.containers.IASServerSessionImpl@19e3e24
    [01/Mar/2004:10:07:55] SEVERE ( 657): MDB00017: [ServerMessageDrivenBean]: Exception in creating message-driven bean container: [javax.jms.JMSException: MQJMS1010: not implemented]
    [01/Mar/2004:10:07:55] FINEST ( 657): run(): after wait ... com.iplanet.ias.ejb.containers.IASServerSessionImpl@19e3e24
    [01/Mar/2004:10:07:55] SEVERE ( 657): javax.jms.JMSException
    javax.jms.JMSException: MQJMS1010: not implemented
         at com.ibm.mq.jms.services.ConfigEnvironment.newException(ConfigEnvironment.java:418)
         at com.ibm.mq.jms.MQQueueConnection.createConnectionConsumer(MQQueueConnection.java:602)
         at com.sun.enterprise.jms.ConnectionWrapperBase.createConnectionConsumer(ConnectionWrapperBase.java:151)
         at com.sun.ejb.containers.MessageBeanHelperQueueImpl.doSetup(MessageBeanHelperQueueImpl.java:67)
         at com.sun.ejb.containers.MessageBeanHelperBase.setup(MessageBeanHelperBase.java:419)
         at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:206)
         at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:173)
         at com.iplanet.ias.server.AbstractLoader.loadEjbs(AbstractLoader.java:345)
         at com.iplanet.ias.server.ApplicationLoader.load(ApplicationLoader.java:81)
         at com.iplanet.ias.server.AbstractManager.load(AbstractManager.java:134)
         at com.iplanet.ias.server.ApplicationLifecycle.onStartup(ApplicationLifecycle.java:168)
         at com.iplanet.ias.server.ApplicationServer.onStartup(ApplicationServer.java:269)
         at com.iplanet.ias.server.J2EERunner.confPostInit(J2EERunner.java:162)
    [01/Mar/2004:10:07:55] SEVERE ( 657): EJB5090: Exception in creating EJB container [javax.jms.JMSException: MQJMS1010: not implemented]
    [01/Mar/2004:10:07:55] SEVERE ( 657): appId=emi moduleName=emiEjb_jar ejbName=ServerMessageDrivenBean
    [01/Mar/2004:10:07:55] SEVERE ( 657): LDR5004: UnExpected error occured while creating ejb container
    javax.jms.JMSException: MQJMS1010: not implemented
         at com.ibm.mq.jms.services.ConfigEnvironment.newException(ConfigEnvironment.java:418)
         at com.ibm.mq.jms.MQQueueConnection.createConnectionConsumer(MQQueueConnection.java:602)
         at com.sun.enterprise.jms.ConnectionWrapperBase.createConnectionConsumer(ConnectionWrapperBase.java:151)
         at com.sun.ejb.containers.MessageBeanHelperQueueImpl.doSetup(MessageBeanHelperQueueImpl.java:67)
         at com.sun.ejb.containers.MessageBeanHelperBase.setup(MessageBeanHelperBase.java:419)
         at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:206)
         at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:173)
         at com.iplanet.ias.server.AbstractLoader.loadEjbs(AbstractLoader.java:345)
         at com.iplanet.ias.server.ApplicationLoader.load(ApplicationLoader.java:81)
         at com.iplanet.ias.server.AbstractManager.load(AbstractManager.java:134)
         at com.iplanet.ias.server.ApplicationLifecycle.onStartup(ApplicationLifecycle.java:168)
         at com.iplanet.ias.server.ApplicationServer.onStartup(ApplicationServer.java:269)
         at com.iplanet.ias.server.J2EERunner.confPostInit(J2EERunner.java:162)
    [01/Mar/2004:10:07:55] WARNING ( 657): CORE5021: Application NOT loaded: [emi]
    [01/Mar/2004:10:07:55] INFO ( 657): WEB0100: Loading web module [mfs:mfs.war] in virtual server [MFPProcessing] at [mfs]
    [01/Mar/2004:10:08:31] INFO ( 657): HTTP3072: HTTP listener http-listener-1 [http://ch042dysz0405:1080] ready to accept requests
    [01/Mar/2004:10:08:31] INFO ( 657): CORE3274: successful server startup
    [01/Mar/2004:10:08:33] INFO ( 657): CORE5053: Application onReady complete.

    Hi,
    You have not created the jms destination queue object
    jms/Warehouse
    Your server logs says it cannot find the destination queue object.It has got nothing to do with jndi name of your bean
    Create jms destination queue object using
    asadmin>create-jms-resource instance <instance_name> resourcetype javax.jms.Queue --property imqDestinationName=<NAme>  jms/Warehouse
    Then use list-jms-resources <instance_name> to
    find if jms/Warehouse destionation queue object has been created.
    Get back in case of any issues

  • Assining Identity to Message Driven Bean

    Dear All,
    I have a problem on connecting MDB to JMS administered object in iPlanet server.
    In the administered object I create an ACI to allows only a certain member of
    group can access this ao. Disallowing anonymous user to connect to the ldap server
    give me this error.
    <Apr 15, 2003 1:41:09 PM SGT> <Warning> <EJB> <010096> <The Message-Driven EJB:
    MessageEJB is unable to connect to the J
    MS destination: cn=ocsQueue. Connection failed after 365 attempts. The MDB will
    attempt to reconnect every 10 seconds, t
    his log message will repeat every 600 seconds until the condition clears.>
    <Apr 15, 2003 1:41:09 PM SGT> <Warning> <EJB> <010061> <The Message-Driven EJB:
    MessageEJB is unable to connect to the J
    MS destination: cn=ocsQueue. The EJB container will automatically attempt to re-establish
    the connection with the JMS se
    rver. This warning may occur during WebLogic Cluster start-up if the JMS destination
    is located on another server. When
    the JMS server connection is re-established, the Message-Driven EJB will again
    receive JMS messages.
    The Error was:
    The Message-Driven EJB attempted to connect to the JMS destination with the JNDI
    name: cn=ocsQueue. However, the object
    with the JNDI name: cn=ocsQueue is not a JMS destination, or the destination found
    was of the wrong type (Topic or Queue
    ).>
    How can I configure the security descriptor so that my MDB can gen a connection
    to ldap to read the administered object.
    I am working on WebLogic 7.0 sp1 and iPlanet
    Thanks,
    Wayan

    Hi Yang,
    The J2EE tutorial will give some more information.
    http://java.sun.com/j2ee/1.4/docs/tutorial/doc/
    See Ch. 28 A Message-Driven Bean example. It has some tips on using deploytool.
    Hope this helps,
    J

  • 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}

Maybe you are looking for