Message Driven Bean -- Instance Creation..

As we know MDB (inJMS) acts as a listener to a message coming from either a topic/queue. The instance of MDB is created by the EJB Container and the no. of instances created depend upon the corresponding values specified in the Deployment-Descriptor. So we never have to create instance of MDB bcoz container takes care of itself. MDB is eventDriven and the method onMessage is fired when topic/queue receives a message.
Now, can I have a scenario where my client creates an instance of MDB explicitly. Say I have an MDB by name TestMDB, I create an instance of MDB using new keyword something like the below code:
TestMDB testMDB = new TestMDB();
The client grabs messages which are recd. using onMessage of TestMDB. I put the msgs recd. in onMessage method into some kind of HashMap and return it to the client. This for sure satisfies my requirement, but EJB specification says MDB instances are created by the EJB Container itslef and that does not give me an easy feeling.
Are there any caveats of creating instances of Message Driven Bean ??

Hi,
Why would you like to create your own MDB instance?
Is it because you don�t want to use an EJB container?
Otherwise, you should know that the container is doing a lot of work under the cover. It is not that simple to achieved concurrent message processing.
I would really recommend you to either use an EJB container or to redesign your application. If you really don�t want to use a heavy weight EJB container you can have a look at Arjuna�MDS that provides you with a light weight container allowing to deploy MDBs like applications.
Hope this helps,
Arnaud
www.arjuna.com

Similar Messages

  • Message-driven bean deployment error

    Hi:
    When attempting to deploy a message-driven bean to the server I get a the following error message:SEVERE: MDB00030: [MessageControllerJAR:MessageControllerEJB]: Exception in setting up message-drive
    n bean container: [[C4003]: Error occurred on connection creation. - caught java.lang.NumberFormatEx
    ception] However, bindings to the queues seem to be created successfully, as evidenced here:
    INFO: CORE5076: Using Java HotSpot(TM) Server VM, Version 1.4.2_02 from Sun Microsystems Inc.
    INFO: JTS5014: Recoverable JTS instance, serverId is 100
    INFO: RAR5060: Install JDBC Datasources ...
    INFO: JMS5015: Install JMS resources ...
    INFO: JMS5002: Binding [< JMS Destination: jms/Sample, javax.jms.Queue, [ imqDestinationName=sample] >]
    INFO: JMS5002: Binding [< JMS Connection Factory: jms/SampleQCF, javax.jms.QueueConnectionFactory [imqBrokerHostName=localhost , imqBrokerHostPort=7222 ] >]
    INFO: LDR5010: All ejb(s) of [stateless-simple] loaded successfully!
    INFO: WEB0100: Loading web module [stateless-simple:stateless-simple.war] in virtual server [server1
    ] at [helloworld]
    INFO: HTTP3072: HTTP listener http-listener-1 [http://xxxxxx:99] ready to accept requests
    startup: server started successfully
    INFO: CORE3274: successful server startup
    I'm using an external JMS provider and according to them the problem is not their server. If we look at the exception trace (javax.jms.JMSException) this is what gets displayed in the server's console:
    SEVERE: MDB00030: [MessageControllerJAR:MessageControllerEJB]: Exception in setting up message-drive
    n bean container: [[C4003]: Error occurred on connection creation. - caught java.lang.NumberFormatEx
    ception]
    SEVERE: MDB00017: [MessageControllerEJB]: Exception in creating message-driven bean container: [java
    x.jms.JMSException: [C4003]: Error occurred on connection creation. - caught java.lang.NumberFormatE
    xception]
    SEVERE: javax.jms.JMSException
    javax.jms.JMSException: [C4003]: Error occurred on connection creation. - caught java.lang.NumberFor
    matException
            at com.sun.messaging.jmq.jmsclient.ExceptionHandler.getJMSException(ExceptionHandler.java:183)
            at com.sun.messaging.jmq.jmsclient.ExceptionHandler.handleException(ExceptionHandler.java:136)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.readBrokerPorts(PortMapperClient.java:145)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.init(PortMapperClient.java:86)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.<init>(PortMapperClient.java:47)
            at com.sun.messaging.jmq.jmsclient.protocol.tcp.TCPConnectionHandler.<init>(TCPConnectionHandler.java:46)
            at com.sun.messaging.jmq.jmsclient.protocol.tcp.TCPStreamHandler.openConnection(TCPStreamHandler.java:101)
            at com.sun.messaging.jmq.jmsclient.ProtocolHandler.init(ProtocolHandler.java:501)
            at com.sun.messaging.jmq.jmsclient.ProtocolHandler.<init>(ProtocolHandler.java:930)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.openConnection(ConnectionImpl.java:1482)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.init(ConnectionImpl.java:403)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.<init>(ConnectionImpl.java:234)
            at com.sun.messaging.jmq.jmsclient.UnifiedConnectionImpl.<init>(UnifiedConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.QueueConnectionImpl.<init>(QueueConnectionImpl.java:32)
            at com.sun.messaging.jmq.jmsclient.XAQueueConnectionImpl.<init>(XAQueueConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionImpl.<init>(JMSXAQueueConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionFactoryImpl.createXAQueueConnection(JMSXAQueueConnectionFactoryImpl.java:75)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionFactoryImpl.createXAQueueConnection(JMSXAQueueConnectionFactoryImpl.java:51)
            at com.sun.enterprise.jms.ConnectionFactoryWrapper.createQueueConnection(ConnectionFactoryWrapper.java:118)
            at com.sun.ejb.containers.MessageBeanHelperBase.setup(MessageBeanHelperBase.java:394)
            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.EJBModuleLoader.load(EJBModuleLoader.java:79)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:194)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:166)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:297)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:464)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:451)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:294)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:99)
            at com.iplanet.ias.admin.server.core.channel.AdminChannelServer.sendNotification(AdminChannelServer.java:84)
            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 sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
            at sun.rmi.transport.Transport$1.run(Transport.java:148)
            at java.security.AccessController.doPrivileged(Native Method)
            at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
            at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
            at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
            at java.lang.Thread.run(Thread
    SEVERE: EJB5090: Exception in creating EJB container [javax.jms.JMSException: [C4003]: Error occurre
    d on connection creation. - caught java.lang.NumberFormatException]
    SEVERE: appId=MessageControllerJAR moduleName=MessageControllerJAR ejbName=MessageControllerEJB
    SEVERE: LDR5004: UnExpected error occured while creating ejb container
    javax.jms.JMSException: [C4003]: Error occurred on connection creation. - caught java.lang.NumberFor
    matException
            at com.sun.messaging.jmq.jmsclient.ExceptionHandler.getJMSException(ExceptionHandler.java:183)
            at com.sun.messaging.jmq.jmsclient.ExceptionHandler.handleException(ExceptionHandler.java:136)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.readBrokerPorts(PortMapperClient.java:145)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.init(PortMapperClient.java:86)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.<init>(PortMapperClient.java:47)
            at com.sun.messaging.jmq.jmsclient.protocol.tcp.TCPConnectionHandler.<init>(TCPConnectionHandler.java:46)
            at com.sun.messaging.jmq.jmsclient.protocol.tcp.TCPStreamHandler.openConnection(TCPStreamHandler.java:101)
            at com.sun.messaging.jmq.jmsclient.ProtocolHandler.init(ProtocolHandler.java:501)
            at com.sun.messaging.jmq.jmsclient.ProtocolHandler.<init>(ProtocolHandler.java:930)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.openConnection(ConnectionImpl.java:1482)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.init(ConnectionImpl.java:403)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.<init>(ConnectionImpl.java:234)
            at com.sun.messaging.jmq.jmsclient.UnifiedConnectionImpl.<init>(UnifiedConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.QueueConnectionImpl.<init>(QueueConnectionImpl.java:32)
            at com.sun.messaging.jmq.jmsclient.XAQueueConnectionImpl.<init>(XAQueueConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionImpl.<init>(JMSXAQueueConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionFactoryImpl.createXAQueueConnection(JMSXAQueueConnectionFactoryImpl.java:75)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionFactoryImpl.createXAQueueConnection(JMSXAQueueConnectionFactoryImpl.java:51)
            at com.sun.enterprise.jms.ConnectionFactoryWrapper.createQueueConnection(ConnectionFactoryWrapper.java:118)
            at com.sun.ejb.containers.MessageBeanHelperBase.setup(MessageBeanHelperBase.java:394)
            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.EJBModuleLoader.load(EJBModuleLoader.java:79)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:194)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:166)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:297)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:464)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:451)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:294)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:99)
            at com.iplanet.ias.admin.server.core.channel.AdminChannelServer.sendNotification(AdminChannelServer.java:84)
            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 sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
            at sun.rmi.transport.Transport$1.run(Transport.java:148)
            at java.security.AccessController.doPrivileged(Native Method)
            at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
            at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
            at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.ja
    WARNING: CORE5020: Error while loading ejb module
    WARNING: ADM5603:Event listener error [Error while loading EJB module [MessageControllerJAR]. Please refer to the server log for more details. Any suggestions will be appreciated. Thanks. SC

    Hi:
    When attempting to deploy a message-driven bean to the server I get a the following error message:SEVERE: MDB00030: [MessageControllerJAR:MessageControllerEJB]: Exception in setting up message-drive
    n bean container: [[C4003]: Error occurred on connection creation. - caught java.lang.NumberFormatEx
    ception] However, bindings to the queues seem to be created successfully, as evidenced here:
    INFO: CORE5076: Using Java HotSpot(TM) Server VM, Version 1.4.2_02 from Sun Microsystems Inc.
    INFO: JTS5014: Recoverable JTS instance, serverId is 100
    INFO: RAR5060: Install JDBC Datasources ...
    INFO: JMS5015: Install JMS resources ...
    INFO: JMS5002: Binding [< JMS Destination: jms/Sample, javax.jms.Queue, [ imqDestinationName=sample] >]
    INFO: JMS5002: Binding [< JMS Connection Factory: jms/SampleQCF, javax.jms.QueueConnectionFactory [imqBrokerHostName=localhost , imqBrokerHostPort=7222 ] >]
    INFO: LDR5010: All ejb(s) of [stateless-simple] loaded successfully!
    INFO: WEB0100: Loading web module [stateless-simple:stateless-simple.war] in virtual server [server1
    ] at [helloworld]
    INFO: HTTP3072: HTTP listener http-listener-1 [http://xxxxxx:99] ready to accept requests
    startup: server started successfully
    INFO: CORE3274: successful server startup
    I'm using an external JMS provider and according to them the problem is not their server. If we look at the exception trace (javax.jms.JMSException) this is what gets displayed in the server's console:
    SEVERE: MDB00030: [MessageControllerJAR:MessageControllerEJB]: Exception in setting up message-drive
    n bean container: [[C4003]: Error occurred on connection creation. - caught java.lang.NumberFormatEx
    ception]
    SEVERE: MDB00017: [MessageControllerEJB]: Exception in creating message-driven bean container: [java
    x.jms.JMSException: [C4003]: Error occurred on connection creation. - caught java.lang.NumberFormatE
    xception]
    SEVERE: javax.jms.JMSException
    javax.jms.JMSException: [C4003]: Error occurred on connection creation. - caught java.lang.NumberFor
    matException
            at com.sun.messaging.jmq.jmsclient.ExceptionHandler.getJMSException(ExceptionHandler.java:183)
            at com.sun.messaging.jmq.jmsclient.ExceptionHandler.handleException(ExceptionHandler.java:136)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.readBrokerPorts(PortMapperClient.java:145)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.init(PortMapperClient.java:86)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.<init>(PortMapperClient.java:47)
            at com.sun.messaging.jmq.jmsclient.protocol.tcp.TCPConnectionHandler.<init>(TCPConnectionHandler.java:46)
            at com.sun.messaging.jmq.jmsclient.protocol.tcp.TCPStreamHandler.openConnection(TCPStreamHandler.java:101)
            at com.sun.messaging.jmq.jmsclient.ProtocolHandler.init(ProtocolHandler.java:501)
            at com.sun.messaging.jmq.jmsclient.ProtocolHandler.<init>(ProtocolHandler.java:930)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.openConnection(ConnectionImpl.java:1482)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.init(ConnectionImpl.java:403)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.<init>(ConnectionImpl.java:234)
            at com.sun.messaging.jmq.jmsclient.UnifiedConnectionImpl.<init>(UnifiedConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.QueueConnectionImpl.<init>(QueueConnectionImpl.java:32)
            at com.sun.messaging.jmq.jmsclient.XAQueueConnectionImpl.<init>(XAQueueConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionImpl.<init>(JMSXAQueueConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionFactoryImpl.createXAQueueConnection(JMSXAQueueConnectionFactoryImpl.java:75)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionFactoryImpl.createXAQueueConnection(JMSXAQueueConnectionFactoryImpl.java:51)
            at com.sun.enterprise.jms.ConnectionFactoryWrapper.createQueueConnection(ConnectionFactoryWrapper.java:118)
            at com.sun.ejb.containers.MessageBeanHelperBase.setup(MessageBeanHelperBase.java:394)
            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.EJBModuleLoader.load(EJBModuleLoader.java:79)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:194)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:166)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:297)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:464)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:451)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:294)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:99)
            at com.iplanet.ias.admin.server.core.channel.AdminChannelServer.sendNotification(AdminChannelServer.java:84)
            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 sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
            at sun.rmi.transport.Transport$1.run(Transport.java:148)
            at java.security.AccessController.doPrivileged(Native Method)
            at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
            at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
            at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
            at java.lang.Thread.run(Thread
    SEVERE: EJB5090: Exception in creating EJB container [javax.jms.JMSException: [C4003]: Error occurre
    d on connection creation. - caught java.lang.NumberFormatException]
    SEVERE: appId=MessageControllerJAR moduleName=MessageControllerJAR ejbName=MessageControllerEJB
    SEVERE: LDR5004: UnExpected error occured while creating ejb container
    javax.jms.JMSException: [C4003]: Error occurred on connection creation. - caught java.lang.NumberFor
    matException
            at com.sun.messaging.jmq.jmsclient.ExceptionHandler.getJMSException(ExceptionHandler.java:183)
            at com.sun.messaging.jmq.jmsclient.ExceptionHandler.handleException(ExceptionHandler.java:136)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.readBrokerPorts(PortMapperClient.java:145)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.init(PortMapperClient.java:86)
            at com.sun.messaging.jmq.jmsclient.PortMapperClient.<init>(PortMapperClient.java:47)
            at com.sun.messaging.jmq.jmsclient.protocol.tcp.TCPConnectionHandler.<init>(TCPConnectionHandler.java:46)
            at com.sun.messaging.jmq.jmsclient.protocol.tcp.TCPStreamHandler.openConnection(TCPStreamHandler.java:101)
            at com.sun.messaging.jmq.jmsclient.ProtocolHandler.init(ProtocolHandler.java:501)
            at com.sun.messaging.jmq.jmsclient.ProtocolHandler.<init>(ProtocolHandler.java:930)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.openConnection(ConnectionImpl.java:1482)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.init(ConnectionImpl.java:403)
            at com.sun.messaging.jmq.jmsclient.ConnectionImpl.<init>(ConnectionImpl.java:234)
            at com.sun.messaging.jmq.jmsclient.UnifiedConnectionImpl.<init>(UnifiedConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.QueueConnectionImpl.<init>(QueueConnectionImpl.java:32)
            at com.sun.messaging.jmq.jmsclient.XAQueueConnectionImpl.<init>(XAQueueConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionImpl.<init>(JMSXAQueueConnectionImpl.java:33)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionFactoryImpl.createXAQueueConnection(JMSXAQueueConnectionFactoryImpl.java:75)
            at com.sun.messaging.jmq.jmsclient.JMSXAQueueConnectionFactoryImpl.createXAQueueConnection(JMSXAQueueConnectionFactoryImpl.java:51)
            at com.sun.enterprise.jms.ConnectionFactoryWrapper.createQueueConnection(ConnectionFactoryWrapper.java:118)
            at com.sun.ejb.containers.MessageBeanHelperBase.setup(MessageBeanHelperBase.java:394)
            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.EJBModuleLoader.load(EJBModuleLoader.java:79)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:194)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:166)
            at com.iplanet.ias.server.StandAloneEJBModulesManager.moduleDeployed(StandAloneEJBModulesManager.java:297)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:464)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.handleModuleDeployEvent(AdminEventMulticaster.java:451)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.processEvent(AdminEventMulticaster.java:294)
            at com.iplanet.ias.admin.event.AdminEventMulticaster.multicastEvent(AdminEventMulticaster.java:99)
            at com.iplanet.ias.admin.server.core.channel.AdminChannelServer.sendNotification(AdminChannelServer.java:84)
            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 sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
            at sun.rmi.transport.Transport$1.run(Transport.java:148)
            at java.security.AccessController.doPrivileged(Native Method)
            at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
            at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
            at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.ja
    WARNING: CORE5020: Error while loading ejb module
    WARNING: ADM5603:Event listener error [Error while loading EJB module [MessageControllerJAR]. Please refer to the server log for more details. Any suggestions will be appreciated. Thanks. SC

  • WebLogic 10 and EJB 3.0 for Message Driven Bean

    Hi,
    I am trying to deploy Message Driven Bean using EJB3.0 on weblogic 10. I am using annotations and don't want to use deployment descriptors.
    The Bean class:
    CalculatorBean.java
    import javax.ejb.*;
    import javax.jms.*;
    import java.sql.Timestamp;
    import java.util.StringTokenizer;
    @MessageDriven(activationConfig =
    @ActivationConfigProperty(propertyName="destinationType",
    propertyValue="javax.jms.Queue"),
    @ActivationConfigProperty(propertyName="destination",
    propertyValue="queue/mdb")
    public class CalculatorBean implements MessageListener {
    public void onMessage (Message msg) {
    TextMessage tmsg=null;
    try {
    if (msg instanceof TextMessage) {
    tmsg = (TextMessage) msg;
    System.out.println
    ("MESSAGE BEAN1: Message received: "
    + tmsg.getText());
    } else {
    System.out.println
    ("Message of wrong type1: "
    + msg.getClass().getName());
    catch (JMSException e) {
    e.printStackTrace();
    catch (Throwable te) {
    te.printStackTrace();
    My client:
    import javax.naming.*;
    import javax.naming.InitialContext;
    import java.text.*;
    import javax.jms.*;
    public class MsgClient {
    public static void main(String args[])
    QueueConnection cnn=null;
    QueueSender sender=null;
    QueueSession sess=null;
    Queue queue=null;
    try {
    java.util.Properties p = new java.util.Properties();
    p.put("java.naming.factory.initial","weblogic.jndi.WLInitialContextFactory");
    p.put("java.naming.provider.url","t3://10.6.74.79:7001");
    Context ctx=new InitialContext(p);
    //InitialContext ctx=new InitialContext(p);
    queue = (Queue)ctx.lookup("queue/mdb");
    QueueConnectionFactory factory = (QueueConnectionFactory)ctx.lookup("ConnectionFactory");
    cnn = factory.createQueueConnection();
    sess= cnn.createQueueSession(false, QueueSession.AUTO_ACKNOWLEDGE);
    sender = sess.createSender(queue);
    TextMessage message = sess.createTextMessage();
    message.setText("This is message by Gurumurthy" );
    System.out.println("Sending message: " +message.getText());
    sender.send(message);
    sess.close();
    catch (Exception e)
    e.printStackTrace();
    I am compiling and creating jar file for this class. Then I am creating a .ear file for this.
    The meta-inf/application.xml contains the following:
    <?xml version="1.0" encoding="UTF-8"?>
    <application xmlns="http://java.sun.com/xml/ns/j2ee" version="1.4"
    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/application_1_4.xsd">
    <display-name>MDBWorking1</display-name>
    <description>Application description</description>
    <module>
    <ejb>MDBWorking1.jar</ejb>
    </module>
    </application>
    I don't want to use deployment descriptor (ejb-jar.xml or weblogic-ejb-jar-xml), because I want to utilize the annotation feature of EJB3.0
    So, after creating the .ear file for this, and try to deploy on weblogic 10, I get the following error:
    An error occurred during activation of changes, please see the log for details.
    Exception preparing module: EJBModule(MDBWorking1.jar) Unable to deploy EJB: CalculatorBean from MDBWorking1.jar: [EJB:011113]Error: The Message Driven Bean 'CalculatorBean(Application: MDBWorking1, EJBComponent: MDBWorking1.jar)', does not have a message destination configured. The message destination must be set using a message-destination-link, destination-resource-link, destination-jndi-name or a resource-adapter-jndi-name.
    Substituted for missing class [EJB - 11113]Error: The Message Driven Bean 'CalculatorBean(Application: MDBWorking1, EJBComponent: MDBWorking1.jar)', does not have a message destination configured. The message destination must be set using a message-destination-link, destination-resource-link, destination-jndi-name or a resource-adapter-jndi-name.
    How to solve this?
    Note:
    I don't want to use Deployment Descriptor and all I want to use is EJB3.0's annotation feature.
    Thanks,
    Guru

    Dear gurubbc,
    I don't know if it still matters to you but you can use the javax.ejb.MessageDriven annotation to point your bean on your queue. I had the same issue like you but i could not solve it properly by switchihg to weblogic.ejb.MessageDriven.
    Use the following annotation and it should work out:
    @MessageDriven
    (mappedName = "queue/mdb",
    name = "CalculatorBean",
    activationConfig = {
    @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue")
    Here you can see that the mappedName is the JNDI name of the queue you are trying to connect to. The name is the name for your Bean, and the only property passed is the destination type.
    Hope this helps.
    Cheers,
    Istvan

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

  • Message Acknowledgement in a Message Driven Bean

    Does the message acknowledgement in a Message driven bean take place after the transaction commits? Will the message be available to be consumed by another instance of the MDB in case the transaction was rolled back? I am using WLS 7.0 as my app server and SonicMQ as JMS provider.
              Thx.
              Ajanta.
              

    Yes, ack's are delayed until the transaction commits.
              Yes, the message will be available if the transaction is rolled back.
              "Ajanta Dey" <[email protected]> wrote in message
              news:3ea616e0$[email protected]..
              > Does the message acknowledgement in a Message driven bean take place after
              the transaction commits? Will the message be available to be consumed by
              another instance of the MDB in case the transaction was rolled back? I am
              using WLS 7.0 as my app server and SonicMQ as JMS provider.
              >
              > Thx.
              > Ajanta.
              

  • 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

  • Exception in setting up message-driven bean container

    hello,
    I'm trying to deploy a single mdb and I'm getting an exception. I've tried closely following the way things are done with the mdb example in the samples AppServer7 directory. Am I missing something in one of my deployment descriptior files?
    Thanks,
    Robert
    [17/Apr/2003:12:18:24] SEVERE ( 1832): MDB00030: [mdb2-simpleEjb:MessageProcessorBean]: Exception in setting up message-driven bean container: [[C4060]: Login failed.]
    [17/Apr/2003:12:18:24] FINE ( 1832): MDB00018: [mdb2-simpleEjb:MessageProcessorBean]: Closing message-driven bean container connection
    [17/Apr/2003:12:18:24] SEVERE ( 1832): MDB00017: [MessageProcessorBean]: Exception in creating message-driven bean container: [javax.jms.JMSSecurityException: [C4060]: Login failed.]
    [17/Apr/2003:12:18:24] SEVERE ( 1832): javax.jms.JMSSecurityException
    javax.jms.JMSSecurityException: [C4060]: Login failed.
         at com.sun.messaging.jmq.jmsclient.ProtocolHandler.authenticate(ProtocolHandler.java:682)
         at com.sun.messaging.jmq.jmsclient.ProtocolHandler.hello(ProtocolHandler.java:615)
         at com.sun.messaging.jmq.jmsclient.ConnectionImpl.hello(ConnectionImpl.java:238)
         at com.sun.messaging.jmq.jmsclient.ConnectionImpl.openConnection(ConnectionImpl.java:1512)
         at com.sun.messaging.jmq.jmsclient.ConnectionImpl.init(ConnectionImpl.java:403)
         at com.sun.messaging.jmq.jmsclient.ConnectionImpl.<init>(ConnectionImpl.java:234)

    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

  • Usage of Apache Beehive JMS control inside Message Driven Bean

    Hi,
    I am developing a j2ee application using weblogic workshop 10.3. This application contains the following three projects.
    - J2EE Utility Project
    - Message Driven Bean Project
    - Ear Project
    In the Utility project I have created one apache beehive jms control. I am using this control inside the message driven bean application. I haven't got any issues during the development and deployment phase with the beehive control. But during runtime the apache beehive jms control is not getting instantiated and the mdb application is throwing the null pointer exception when the EJB container try to execute the methods on the control instance. I have used the declarative programming model to create the control instance inside the mdb application.
    I am using the weblogic 10.3 server for testing and I have created the 10.3 weblogic+workshop domain. By default it has the beehive libraries deployed.
    Can somebody help me out to resolve this issue?
    Regards,
    Bp

    You can get the message directly with getText() method. Following is the snippet of code.
    if (aMsg instanceof TextMessage) {
    TextMessage msg = (TextMessage) aMsg;
    String testMessage = msg.getText());
    Kishore.

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

  • Deployment of Message Driven Bean fails

    Hi guys,
    i use MQSeries as JMS Provider.
    The Application (ear) has the following structure :
    MDBApp.ear
    contains
      mqseries1.jar ,mqseries2.jar, mqseries3.jar , .. ( In the previous Version of NetWeaver is used a deployable                                                           Server library and referenced it from the jms-factories.xml )
      mdb.jar  (contains the Message Driven Bean)
    Note : 
    the jms-resources.xml has the following content :
    <?xml version="1.0" encoding="UTF-8"?>
    <jms-resources xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="jms-resources.xsd">
         <connection-factory>
              <name>TestFactory</name>
              <object-factory-type>
                   <object-factory-name>com.ibm.mq.jms.MQXAQueueConnectionFactoryFactory</object-factory-name>
                   <class-name>com.ibm.mq.jms.MQXAQueueConnectionFactory</class-name>
                   <property>
                        <config-property-name>HOST</config-property-name>
                        <config-property-value>anIPAdress</config-property-value>
                   </property>
                   <property>
                        <config-property-name>QMGR</config-property-name>
                        <config-property-value>aQueueManagerID</config-property-value>
                   </property>
                   <property>
                        <config-property-name>PORT</config-property-name>
                        <config-property-value>aPort</config-property-value>
                   </property>
                   <property>
                        <config-property-name>TRAN</config-property-name>
                        <config-property-value>1</config-property-value>
                   </property>
              </object-factory-type>
         </connection-factory>
         <destination>
              <name>RA.IBMSOLLIST.ASSOLLIST.001</name>
              <type>javax.jms.Queue</type>
              <external-destination-type>
                   <link-connection-factory>TestFactory</link-connection-factory>
              </external-destination-type>
         </destination>
    </jms-resources>
    The Message Driven Bean code :
    @MessageDriven(activationConfig = {
              @ActivationConfigProperty(propertyName = "destinationType",
              propertyValue = "javax.jms.Queue"),
              @ActivationConfigProperty(propertyName = "destination",
              propertyValue = "RA.IBMSOLLIST.ASSOLLIST.001"),
              @ActivationConfigProperty(propertyName =
              "connectionFactoryName", propertyValue = "TestFactory")
    public class VMRaTestMessageDBean implements MessageListener {
         /* (non-Javadoc)
    @see javax.jms.MessageListener#onMessage(javax.jms.Message)
         public void onMessage(Message arg0) {
              // TODO Auto-generated method stub
    The SDM gets following warning/error :
         Description:
              1. Exception has been returned while the 'vmtubes.de/ratestmdb~ear' was starting. Warning/Exception :
    [ERROR CODE DPL.DS.6193] Error while ; nested exception is:
         com.sap.engine.services.deploy.exceptions.ServerDeploymentException: [ERROR CODE DPL.DS.5030] Clusterwide exception: server ID 2198950:com.sap.engine.services.deploy.container.DeploymentException: Cannot activate endpoint for message-driven bean vmtubes.de/ratestmdbear*annotation|vmtubes.deratestmdb~ejb.jar*annotation|VMRaTestMessageDBean
         at com.sap.engine.services.ejb3.container.ContainerInterfaceImpl$Actions.perform(ContainerInterfaceImpl.java:893)
         at com.sap.engine.services.ejb3.container.ContainerInterfaceImpl.prepareStart(ContainerInterfaceImpl.java:425)
         at com.sap.engine.services.deploy.server.application.StartTransaction.prepareCommon(StartTransaction.java:219)
         at com.sap.engine.services.deploy.server.application.StartTransaction.prepare(StartTransaction.java:179)
         at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:420)
         at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhases(ApplicationTransaction.java:445)
         at com.sap.engine.services.deploy.server.application.ParallelAdapter.super_MakeAllPhases(ParallelAdapter.java:337)
         at com.sap.engine.services.deploy.server.application.StartTransaction.makeAllPhasesImpl(StartTransaction.java:550)
         at com.sap.engine.services.deploy.server.application.ParallelAdapter.runInTheSameThread(ParallelAdapter.java:251)
         at com.sap.engine.services.deploy.server.application.ParallelAdapter.makeAllPhasesAndWait(ParallelAdapter.java:392)
         at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3389)
         at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3375)
         at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3278)
         at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3251)
         at com.sap.engine.services.dc.lcm.impl.J2EELCMProcessor.doStart(J2EELCMProcessor.java:99)
         at com.sap.engine.services.dc.lcm.impl.LifeCycleManagerImpl.start(LifeCycleManagerImpl.java:62)
         at com.sap.engine.services.dc.cm.deploy.impl.LifeCycleManagerStartVisitor.visit(LifeCycleManagerStartVisitor.java:34)
         at com.sap.engine.services.dc.cm.deploy.impl.DeploymentItemImpl.accept(DeploymentItemImpl.java:83)
         at com.sap.engine.services.dc.cm.deploy.impl.DefaultDeployPostProcessor.postProcessLCMDeplItem(DefaultDeployPostProcessor.java:80)
         at com.sap.engine.services.dc.cm.deploy.impl.DefaultDeployPostProcessor.postProcess(DefaultDeployPostProcessor.java:56)
         at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.doPostProcessing(DeployerImpl.java:741)
         at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.performDeploy(DeployerImpl.java:732)
         at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.doDeploy(DeployerImpl.java:576)
         at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:270)
         at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:192)
         at com.sap.engine.services.dc.cm.deploy.impl.DeployerImplp4_Skel.dispatch(DeployerImplp4_Skel.java:875)
         at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:351)
         at com.sap.engine.services.rmi_p4.server.ServerDispatchImpl.run(ServerDispatchImpl.java:70)
         at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:62)
         at com.sap.engine.services.rmi_p4.P4Message.execute(P4Message.java:37)
         at com.sap.engine.services.cross.fca.FCAConnectorImpl.executeRequest(FCAConnectorImpl.java:872)
         at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:53)
         at com.sap.engine.services.cross.fca.MessageReader.run(MessageReader.java:58)
         at com.sap.engine.core.thread.execution.Executable.run(Executable.java:108)
         at com.sap.engine.core.thread.execution.CentralExecutor$SingleThread.run(CentralExecutor.java:304)
    Caused by: com.sap.engine.services.ejb3.container.ActionException: Cannot activate endpoint for message-driven bean vmtubes.de/ratestmdbear*annotation|vmtubes.deratestmdb~ejb.jar*annotation|VMRaTestMessageDBean
         at com.sap.engine.services.ejb3.runtime.impl.Actions_MDBEndpointActivation.perform(Actions_MDBEndpointActivation.java:94)
         at com.sap.engine.services.ejb3.container.CompositeAction.perform(CompositeAction.java:81)
         at com.sap.engine.services.ejb3.container.ApplicationStarter.perform(ApplicationStarter.java:59)
         at com.sap.engine.services.ejb3.container.ContainerInterfaceImpl$Actions.perform(ContainerInterfaceImpl.java:887)
         ... 34 more
    Caused by: javax.resource.NotSupportedException: javax.resource.spi.UnavailableException: The destination RA.IBMSOLLIST.ASSOLLIST.001 cannot be looked up. Last attempt performed : jms_vendor_queues_global/RA.IBMSOLLIST.ASSOLLIST.001
         at com.sap.jms.resourceadapter.ResourceAdapterImpl.endpointActivation(ResourceAdapterImpl.java:113)
         at com.sap.engine.services.connector.jca15.EndpointActivationImpl.activateEndpoint(EndpointActivationImpl.java:451)
         at com.sap.engine.services.connector.jca15.EndpointActivationImpl.findResourceAdapterByName(EndpointActivationImpl.java:154)
         at com.sap.engine.services.connector.jca15.EndpointActivationImpl.findAdapter(EndpointActivationImpl.java:85)
         at com.sap.engine.services.connector.jca15.EndpointActivationImpl.activateEndpoint(EndpointActivationImpl.java:58)
         at com.sap.engine.services.ejb3.runtime.impl.Actions_MDBEndpointActivation.perform(Actions_MDBEndpointActivation.java:84)
         ... 37 more
    Caused by: javax.resource.spi.UnavailableException: The destination RA.IBMSOLLIST.ASSOLLIST.001 cannot be looked up. Last attempt performed : jms_vendor_queues_global/RA.IBMSOLLIST.ASSOLLIST.001
         at com.sap.jms.resourceadapter.RaActivation.setupDestination(RaActivation.java:345)
         at com.sap.jms.resourceadapter.RaActivation.activate(RaActivation.java:121)
         at com.sap.jms.resourceadapter.ResourceAdapterImpl.endpointActivation(ResourceAdapterImpl.java:101)
         ... 42 more
    Caused by: com.sap.engine.services.jndi.persistent.exceptions.NameNotFoundException: Object not found in lookup of RA.IBMSOLLIST.ASSOLLIST.001.
         at com.sap.engine.services.jndi.implserver.ServerContextImpl.lookup(ServerContextImpl.java:584)
         at com.sap.engine.services.jndi.implclient.ClientContext.lookup(ClientContext.java:343)
         at com.sap.engine.services.jndi.implclient.ClientContext.lookup(ClientContext.java:637)
         at javax.naming.InitialContext.lookup(InitialContext.java:351)
         at javax.naming.InitialContext.lookup(InitialContext.java:351)
         at com.sap.jms.resourceadapter.RaActivation.setupDestination(RaActivation.java:343)
         ... 44 more
    I use NetWeaver CE 7.1 SP05 .
    Locke

    Hi Vladimir,
    i can't find the string "JMS Connector Container Application: vmtubes.de/ratestmdb~ear destination name: RA.IBMSOLLIST.ASSOLLIST.001" in the traces.
    These are all the logentries while the deployment (read the entries from top to buttom):
    Starting activation of JMS resource adapter endpoint factory. ActivationSpec is :  applicationName=vmtubes.de/ratestmdb~ear,connectionFactoryName : Testfactory,mAcknowledgeMode : null,maxPoolSize : 50,mClientId : null,mDestinationName : RA.IBMSOLLIST.ASSOLLIST.001,mDestinationType : javax.jms.Queue,minPoolSize : 0,mMessageSelector : null,mSubscriptionDurability : null,mSubscriptionName : null,mReconnectAttempts : 10,mSleepBetweenAttempts : 1000,mParallelConsumers : 1
    Performing JNDI lookup for obtaining connectionFactory : jms_vendor_factory_local/vmtubes.de/ratestmdb~ear/Testfactory
    First attempt for lookup failed. That could happen for 6.40 applpication without application name. We will continute with the fallback chain. The JNDI lookup is : jms_vendor_factory_local/vmtubes.de/ratestmdb~ear/Testfactory
    Performing JNDI lookup for obtaining connectionFactory : jms_vendor_factory_global/Testfactory
    Attempt for lookup without application name failed. An attempt will be performed to use the default connectionFactory instead of the one supplied during deployment. The JNDI name is : jms_vendor_factory_global/Testfactory
    Performing JNDI lookup for obtaining connectionFactory : jmsfactory/default/XAQueueConnectionFactory
    JMS connection created:
    ================================== Connection ==================================
    ID                            9444418335539219                                 
    Type                          (Generic)Connection                              
    Mode                          STOPPED                                          
    isClosed                      NO                                               
    client = null
    server = com.sap.jms.server.remote.JMSRemoteServerImpl5ec877
    packetFactory = com.sap.jms.protocol.PacketFactoryImpl12e8d47
    thread pool = null
    isClosed = false
    runFlag  = true
    isRunning = true
    ConnectionMetaData -
    JMSVersion                    1.1                                              
    PorviderVersion               Version 1.0                                      
    SupportedJMSXProperties       JMSXGroupID, JMSXGroupSeq                        
    ================================================================================
    com.sap.jms.client.connection.RemoteQueueConnection13d601c isUsed = false
    Attempt for lookup without application name failed. An attempt will be performed to use the default connectionFactory instead of the one supplied during deployment. The JNDI name is : jms_vendor_factory_global/Testfactory
    Attempt for lookup of destination failed. That could happen for 6.40 applications without application name.An attempt will be performed without the application name. The JNDI name is : jms_vendor_queues_local/vmtubes.de/ratestmdb~ear/RA.IBMSOLLIST.ASSOLLIST.001
    java.lang.ClassCastException: class javax.naming.Reference:null incompatible with interface javax.jms.Destination:library:jmscom.sap.engine.boot.loader.ResourceMultiParentClassLoader389922alive
    at com.sap.jms.resourceadapter.RaActivation.setupDestination(RaActivation.java:320)
    at com.sap.jms.resourceadapter.RaActivation.activate(RaActivation.java:121)
    at com.sap.jms.resourceadapter.ResourceAdapterImpl.endpointActivation(ResourceAdapterImpl.java:101)
    at com.sap.engine.services.connector.jca15.EndpointActivationImpl.activateEndpoint(EndpointActivationImpl.java:451)
    at com.sap.engine.services.connector.jca15.EndpointActivationImpl.findResourceAdapterByName(EndpointActivationImpl.java:154)
    at com.sap.engine.services.connector.jca15.EndpointActivationImpl.findAdapter(EndpointActivationImpl.java:85)
    at com.sap.engine.services.connector.jca15.EndpointActivationImpl.activateEndpoint(EndpointActivationImpl.java:58)
    at com.sap.engine.services.ejb3.runtime.impl.Actions_MDBEndpointActivation.perform(Actions_MDBEndpointActivation.java:84)
    at com.sap.engine.services.ejb3.container.CompositeAction.perform(CompositeAction.java:81)
    at com.sap.engine.services.ejb3.container.ApplicationStarter.perform(ApplicationStarter.java:59)
    at com.sap.engine.services.ejb3.container.ContainerInterfaceImpl$Actions.perform(ContainerInterfaceImpl.java:887)
    at com.sap.engine.services.ejb3.container.ContainerInterfaceImpl.prepareStart(ContainerInterfaceImpl.java:425)
    at com.sap.engine.services.deploy.server.application.StartTransaction.prepareCommon(StartTransaction.java:219)
    at com.sap.engine.services.deploy.server.application.StartTransaction.prepare(StartTransaction.java:179)
    at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:420)
    at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhases(ApplicationTransaction.java:445)
    at com.sap.engine.services.deploy.server.application.ParallelAdapter.super_MakeAllPhases(ParallelAdapter.java:337)
    at com.sap.engine.services.deploy.server.application.StartTransaction.makeAllPhasesImpl(StartTransaction.java:550)
    at com.sap.engine.services.deploy.server.application.ParallelAdapter.runInTheSameThread(ParallelAdapter.java:251)
    at com.sap.engine.services.deploy.server.application.ParallelAdapter.makeAllPhasesAndWait(ParallelAdapter.java:392)
    at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3389)
    at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3375)
    at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3278)
    at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3251)
    at com.sap.engine.services.dc.lcm.impl.J2EELCMProcessor.doStart(J2EELCMProcessor.java:99)
    at com.sap.engine.services.dc.lcm.impl.LifeCycleManagerImpl.start(LifeCycleManagerImpl.java:62)
    at com.sap.engine.services.dc.cm.deploy.impl.LifeCycleManagerStartVisitor.visit(LifeCycleManagerStartVisitor.java:34)
    at com.sap.engine.services.dc.cm.deploy.impl.DeploymentItemImpl.accept(DeploymentItemImpl.java:83)
    at com.sap.engine.services.dc.cm.deploy.impl.DefaultDeployPostProcessor.postProcessLCMDeplItem(DefaultDeployPostProcessor.java:80)
    at com.sap.engine.services.dc.cm.deploy.impl.DefaultDeployPostProcessor.postProcess(DefaultDeployPostProcessor.java:56)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.doPostProcessing(DeployerImpl.java:741)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.performDeploy(DeployerImpl.java:732)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.doDeploy(DeployerImpl.java:576)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:270)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:192)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImplp4_Skel.dispatch(DeployerImplp4_Skel.java:875)
    at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:351)
    at com.sap.engine.services.rmi_p4.server.ServerDispatchImpl.run(ServerDispatchImpl.java:70)
    at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:62)
    at com.sap.engine.services.rmi_p4.P4Message.execute(P4Message.java:37)
    at com.sap.engine.services.cross.fca.FCAConnectorImpl.executeRequest(FCAConnectorImpl.java:872)
    at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:53)
    at com.sap.engine.services.cross.fca.MessageReader.run(MessageReader.java:58)
    at com.sap.engine.core.thread.execution.Executable.run(Executable.java:108)
    at com.sap.engine.core.thread.execution.CentralExecutor$SingleThread.run(CentralExecutor.java:304)
    Connection, destination and serverSession pool have been initialized correctly. Delivery of JMS messages will be started.Connection = ================================== Connection ==================================
    ID                            9444418335539219                                 
    Type                          (Generic)Connection                              
    Mode                          STOPPED                                          
    isClosed                      NO                                               
    ExceptionListener             com.sap.jms.resourceadapter.RaActivation1fe79   
    client = com.sap.jms.server.remote.JMSRemoteClientImpl857822
    server = RMI_P4: Local Dynamic Stub for impl -> com.sap.jms.server.remote.JMSRemoteServerImpl18f254f
    P4 Remote Object Info : com.sap.engine.services.rmi_p4.server.P4ServerObjectInfo100
       |-           broker id : -752547698
       |-           server id : 2198950
       |-           client Id : -1
       |-            local Id : 2198950
       |-     is redirectable : false
       |-         redir Ident :
       |-        factory Name : null
       |-               objId : null
       |-  server loader name : null
       |-           connected : false
       |- supportOptimization : true
       |-            protocol :  76 31                                             v1
            Remote Interfaces :
       Interface : [0] = com.sap.jms.server.remote.JMSRemoteServer
       Interface : [1] = com.sap.engine.services.rmi_p4.interfaces.P4Notification
    =========================================
           Connection profiles :
       connection profile : [0] = None:195.233.66.25:50004
    =========================================
    packetFactory = com.sap.jms.protocol.PacketFactoryImple9cc66
    thread pool = com.sap.engine.core.service630.context.core.thread.ThreadSystemImpl1b57cfa
    isClosed = false
    runFlag  = true
    isRunning = true
    ConnectionMetaData -
    JMSVersion                    1.1                                              
    PorviderVersion               Version 1.0                                      
    SupportedJMSXProperties       JMSXGroupID, JMSXGroupSeq                        
    ================================================================================
    com.sap.jms.client.connection.RemoteQueueConnection16a7da2 isUsed = true, destination = queue:///RA.IBMSOLLIST.ASSOLLIST.001, pool = com.sap.jms.resourceadapter.RaServerSessionPool5e2ae5, activation spec =  applicationName=vmtubes.de/ratestmdb~ear,connectionFactoryName : Testfactory,mAcknowledgeMode : null,maxPoolSize : 50,mClientId : null,mDestinationName : RA.IBMSOLLIST.ASSOLLIST.001,mDestinationType : javax.jms.Queue,minPoolSize : 0,mMessageSelector : null,mSubscriptionDurability : null,mSubscriptionName : null,mReconnectAttempts : 10,mSleepBetweenAttempts : 1000,mParallelConsumers : 1
    JMS session created:
    =================================== Session ====================================
    ID:                           17                                               
    Type:                         (Generic)Session                                 
    ConnectionID:                 9444418335539219                                 
    AcknowledgeMode:              Transacted session!                              
    ================================================================================
    ActivationSpec could not be deployed/started due to internal problem, clean up will be performed, the activation spec was  applicationName=vmtubes.de/ratestmdb~ear,connectionFactoryName : Testfactory,mAcknowledgeMode : null,maxPoolSize : 50,mClientId : null,mDestinationName : RA.IBMSOLLIST.ASSOLLIST.001,mDestinationType : javax.jms.Queue,minPoolSize : 0,mMessageSelector : null,mSubscriptionDurability : null,mSubscriptionName : null,mReconnectAttempts : 10,mSleepBetweenAttempts : 1000,mParallelConsumers : 1
    javax.resource.spi.UnavailableException: javax.jms.InvalidDestinationException: Illegal destination!
    at com.sap.jms.resourceadapter.RaActivation.activate(RaActivation.java:136)
    at com.sap.jms.resourceadapter.ResourceAdapterImpl.endpointActivation(ResourceAdapterImpl.java:101)
    at com.sap.engine.services.connector.jca15.EndpointActivationImpl.activateEndpoint(EndpointActivationImpl.java:451)
    at com.sap.engine.services.connector.jca15.EndpointActivationImpl.findResourceAdapterByName(EndpointActivationImpl.java:154)
    at com.sap.engine.services.connector.jca15.EndpointActivationImpl.findAdapter(EndpointActivationImpl.java:85)
    at com.sap.engine.services.connector.jca15.EndpointActivationImpl.activateEndpoint(EndpointActivationImpl.java:58)
    at com.sap.engine.services.ejb3.runtime.impl.Actions_MDBEndpointActivation.perform(Actions_MDBEndpointActivation.java:84)
    at com.sap.engine.services.ejb3.container.CompositeAction.perform(CompositeAction.java:81)
    at com.sap.engine.services.ejb3.container.ApplicationStarter.perform(ApplicationStarter.java:59)
    at com.sap.engine.services.ejb3.container.ContainerInterfaceImpl$Actions.perform(ContainerInterfaceImpl.java:887)
    at com.sap.engine.services.ejb3.container.ContainerInterfaceImpl.prepareStart(ContainerInterfaceImpl.java:425)
    at com.sap.engine.services.deploy.server.application.StartTransaction.prepareCommon(StartTransaction.java:219)
    at com.sap.engine.services.deploy.server.application.StartTransaction.prepare(StartTransaction.java:179)
    at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:420)
    at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhases(ApplicationTransaction.java:445)
    at com.sap.engine.services.deploy.server.application.ParallelAdapter.super_MakeAllPhases(ParallelAdapter.java:337)
    at com.sap.engine.services.deploy.server.application.StartTransaction.makeAllPhasesImpl(StartTransaction.java:550)
    at com.sap.engine.services.deploy.server.application.ParallelAdapter.runInTheSameThread(ParallelAdapter.java:251)
    at com.sap.engine.services.deploy.server.application.ParallelAdapter.makeAllPhasesAndWait(ParallelAdapter.java:392)
    at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3389)
    at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3375)
    at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3278)
    at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3251)
    at com.sap.engine.services.dc.lcm.impl.J2EELCMProcessor.doStart(J2EELCMProcessor.java:99)
    at com.sap.engine.services.dc.lcm.impl.LifeCycleManagerImpl.start(LifeCycleManagerImpl.java:62)
    at com.sap.engine.services.dc.cm.deploy.impl.LifeCycleManagerStartVisitor.visit(LifeCycleManagerStartVisitor.java:34)
    at com.sap.engine.services.dc.cm.deploy.impl.DeploymentItemImpl.accept(DeploymentItemImpl.java:83)
    at com.sap.engine.services.dc.cm.deploy.impl.DefaultDeployPostProcessor.postProcessLCMDeplItem(DefaultDeployPostProcessor.java:80)
    at com.sap.engine.services.dc.cm.deploy.impl.DefaultDeployPostProcessor.postProcess(DefaultDeployPostProcessor.java:56)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.doPostProcessing(DeployerImpl.java:741)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.performDeploy(DeployerImpl.java:732)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.doDeploy(DeployerImpl.java:576)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:270)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:192)
    at com.sap.engine.services.dc.cm.deploy.impl.DeployerImplp4_Skel.dispatch(DeployerImplp4_Skel.java:875)
    at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:351)
    at com.sap.engine.services.rmi_p4.server.ServerDispatchImpl.run(ServerDispatchImpl.java:70)
    at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:62)
    at com.sap.engine.services.rmi_p4.P4Message.execute(P4Message.java:37)
    at com.sap.engine.services.cross.fca.FCAConnectorImpl.executeRequest(FCAConnectorImpl.java:872)
    at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:53)
    at com.sap.engine.services.cross.fca.MessageReader.run(MessageReader.java:58)
    at com.sap.engine.core.thread.execution.Executable.run(Executable.java:108)
    at com.sap.engine.core.thread.execution.CentralExecutor$SingleThread.run(CentralExecutor.java:304)
    Caused by: javax.jms.InvalidDestinationException: Illegal destination!
    at com.sap.jms.client.session.Session.createConsumer(Session.java:1807)
    at com.sap.jms.client.session.Session.createConsumer(Session.java:1795)
    at com.sap.jms.client.connection.ConnectionConsumer.<init>(ConnectionConsumer.java:124)
    at com.sap.jms.client.connection.Connection.createConnectionConsumer(Connection.java:167)
    at com.sap.jms.resourceadapter.RaActivation.setUpConnectionConsumer(RaActivation.java:165)
    at com.sap.jms.resourceadapter.RaActivation.activate(RaActivation.java:128)
    ... 43 more
    An attempt to stop message delivery will be performed. Activation request was  applicationName=vmtubes.de/ratestmdb~ear,connectionFactoryName : Testfactory,mAcknowledgeMode : null,maxPoolSize : 50,mClientId : null,mDestinationName : RA.IBMSOLLIST.ASSOLLIST.001,mDestinationType : javax.jms.Queue,minPoolSize : 0,mMessageSelector : null,mSubscriptionDurability : null,mSubscriptionName : null,mReconnectAttempts : 10,mSleepBetweenAttempts : 1000,mParallelConsumers : 1
    JMS session closed:
    =================================== Session ====================================
    ID:                           17                                               
    Type:                         (Generic)Session                                 
    ConnectionID:                 9444418335539219                                 
    AcknowledgeMode:              Transacted session!                              
    ================================================================================
    Connection context doesn't exists ! id = 
    Removing unreferenced connection ID =
    Connection context doesn't exists ! id = 
    Connection closed:
    ================================== Connection ==================================
    ID                            9444418335539219                                 
    Type                          (Generic)Connection                              
    Mode                          STOPPED                                          
    isClosed                      YES                                              
    client = com.sap.jms.server.remote.JMSRemoteClientImpl857822
    server = RMI_P4: Local Dynamic Stub for impl -> com.sap.jms.server.remote.JMSRemoteServerImpl18f254f
    P4 Remote Object Info : com.sap.engine.services.rmi_p4.server.P4ServerObjectInfo100
       |-           broker id : -752547698
       |-           server id : 2198950
       |-           client Id : -1
       |-            local Id : 2198950
       |-     is redirectable : false
       |-         redir Ident :
       |-        factory Name : null
       |-               objId : null
       |-  server loader name : null
       |-           connected : false
       |- supportOptimization : true
       |-            protocol :  76 31                                             v1
            Remote Interfaces :
       Interface : [0] = com.sap.jms.server.remote.JMSRemoteServer
       Interface : [1] = com.sap.engine.services.rmi_p4.interfaces.P4Notification
    =========================================
           Connection profiles :
       connection profile : [0] = None:195.233.66.25:50004
    =========================================
    packetFactory = com.sap.jms.protocol.PacketFactoryImple9cc66
    thread pool = com.sap.engine.core.service630.context.core.thread.ThreadSystemImpl1b57cfa
    isClosed = true
    runFlag  = false
    isRunning = true
    ConnectionMetaData -
    JMSVersion                    1.1                                              
    PorviderVersion               Version 1.0                                      
    SupportedJMSXProperties       JMSXGroupID, JMSXGroupSeq                        
    ================================================================================
    com.sap.jms.client.connection.RemoteQueueConnection16a7da2 isUsed = true
    Here the Telnet output :
    >lookup jms_vendor_queues_local/vmtubes.de/ratestmdb~ear/RA.IBMSOLLIST.ASSOLLIST.001
    Trying to connect...
    Connected.
    [Shell -> LOOKUP] Location : /jms_vendor_queues_local/vmtubes.de/ratestmdb~ear
    /RA.IBMSOLLIST.ASSOLLIST.001
    [Shell -> LOOKUP] Contains : Reference Class Name: com.ibm.mq.jms.MQQueue
    Type: VER
    Content: 1
    Type: EXP
    Content: -2
    Type: PRI
    Content: -2
    Type: PER
    Content: -2
    Type: CCS
    Content: 1208
    Type: TC
    Content: 0
    Type: ENC
    Content: 273
    Type: FIQ
    Content: 1
    Type: QU
    Content: RA.IBMSOLLIST.ASSOLLIST.001
    Type: QMGR
    Content:
    [Shell -> LOOKUP] Class name : javax.naming.Reference
    >llr -all -f com/ibm/mq/jms/MQQueue.class
    jar:file:/C:/usr/sap/J2E/J00/j2ee/cluster/bin/ext/MQSLibrary/com.ibm.mq.jms.jar!
    /com/ibm/mq/jms/MQQueue.class
    jar:file:/C:/usr/sap/J2E/J00/j2ee/cluster/apps/vmtubes.de/mq%7Ebase%7Eserver%7El
    ib/app_libraries_container/com.ibm.mq.jms.jar!/com/ibm/mq/jms/MQQueue.class
    Locke

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

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

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

  • WLS10 - message-driven bean init-suspended / max-suspended params

    I have a message-driven bean deployed with my app. I also have a custom start-up class that binds an Oracle AQ to Weblogic's JNDI tree that this message-driven bean connects to. If our DBAs perform database maintanance over the weekend and bring the db down for a period of time, WebLogic 'suspends' the message-driven bean when the db becomes unresponsive.
    This is fine if once the db comes back up, WebLogic would resume the message-driven bean, but it doesn't. Via the admin console, I've tried re-initializing the bean, and I've tried resuming the bean...neither work...both result in a success status but the bean remains with a status of suspended.
    Upon digging, I learned there are two parameters you can set for MDBs in the descriptor file or EJBGen annotations called initSuspendSeconds and maxSuspendSeconds...setting masSuspedSeconds to 0, according to the docs, say the bean will never suspend. I use the EJB annotation methodology and added these to my @MessageDriven annotation block. WebLogic Workshop will not generate these parameters in the resultant descriptor, nor will the build I perform to our development application server.
    I then went to the admin console and manually updated these fields...help docs from the admin console say the default is 0...online docs and my installation on both windows and linux result in a default of 5 for initSuspendSeconds and 60 for maxSuspendSeconds. Ok...so I override these manually from the admin console once I've deployed my application...only thing it does is it requiresthe creation of a deployment plan now and asks for a directory in which to store this deployment plan. Fine...but honestly...what is the deal with these fields that they're being ignored by EJBGen, their defaults do not follow the docs and changing them via the admin console requires a deployment plan?
    Anyone know anything about these params? I'm using WLS10MP1, btw, not 10.3. Not sure if that makes a difference...but just thought I'd include that tidbit.
    Any help is greatly appreciated.
    Thanks,
    Edited by: rlb3778 on Feb 20, 2009 11:56 AM

    So if you add the following annotations to the top of your MDB, EJBGen creates the suspended parameters in the descriptor?
    @MessageDriven(ejbName = "MyBean",
              destinationJndiName = "SOME_QUEUE",
              destinationType = "javax.jms.Queue",
              transTimeoutSeconds = "3600",
              maxBeansInFreePool = "1",
              initialBeansInFreePool = "1",
              initSuspendSeconds = 0,
              maxSuspendSeconds = 0)
    If I sent them to anything BUT 0 they're generated in the descriptor files but it ignores them if they're 0 and I WANT them to be 0 so the beans are never suspended. Oh well. I have a ticket open with support and they've confirmed that when they're et to 0 they're not generated and they claim because that's the default value which according to the spec, isn't...so I'm still waiting to hear back.
    As for the JDBC connection, MDB resumeing upon reconnectiong of DB...our environments are very different...we do not have a JMS server running and maintained by Weblogic...we have a custom start-up class that binds our OracleAQ to Weblogic's JNDI tree and our MDB listens to the queue in the database. So i'm guessing because of that complex setup something is not working when the db queue disconnects. I will investigate our custom start-up class. Thanks for your help.

  • Faulty ObjectMessage Payload in Message Driven Bean

    To all,
    I have a frustrating problem. I am using iPlanet application server 6.5 and Java Message Queue 2.0 beta. I have deployed a message driven bean into the application server. This bean expects ObjectMessage's. The bean successfully receives messages if they are standard java objects, but if the payload is an object of my own making - distributed as part of the deployment jar file - the container throws a RuntimeException when ObjectMessage.getObject() is invoked within onMessage(). This occurs whether I submit the message from outside the container or within it. Note that the sending of the message seems to be successful; no Exception is thrown.
    The object causing the problem is a subclass of Exception and contains two instance variables: one an Exception, and one an instance of its own type. The particular object I am sending has zero depth, by which I mean both instance variables are null. I can see the message in the JMQ persistent store and see that this object has been serialized - or at least there is data in the persistent store that looks like it has been serialized.
    Because the object can be serialized, I was led to believe that this is a classpath issue. However, I added the directory in the app server where the bean is deployed to the CLASSPATH variable in the iasenv.ksh file, and still no luck. The Exception is receive in the kjs log is a simple RuntimeException with the useless tag: The message could not be processed properly.
    Any ideas? I would greatly appreciate any help.
    Marcus

    Hi Xiang,
    I am assuming you are calling a synchronous recveive -- receiver.receive() in order to get the object message sent back from the MDB In that case the current thread classloader will be used. As you can see from the exception :
    uwl.konplan.domino.provider.DominoItem with classloader: com.sap.engine.services.deploy.server.ApplicationLoade
    That is the ApplicationLoader not something from the JMS. So i strongly doubt JMS is the problem.
    Two things that you can check further :
    1) When a deserialization is involved it will try to deserialize the full object graph. I.e. if your dominoItem has a field with class FOO, than the getObject() call must be able to classload FOO. Please check if some classes should be added as well in that portapp.xml of yours
    2)  Make sure that you test to instantiate the DominoObject right before you call getObject() and not in some different thread and logic in your application. Just to be sure that you can really classload it.
    HTH
    Peter

  • 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

  • Message Driven Bean Concurrency

    Hi:
    I am working with message-driven beans (MDB). My understanding was that
    these beans would read and execute concurrently. My tests show they do
    not. I have setup a single MDB which contains the following trivial
    implementation of onMessage...
    public void onMessage(javax.jms.Message message) {
    System.err.println("onMessage()");
    try{
    TextMessage tm = (TextMessage) message;
    String text = tm.getText();
    System.err.println("Received new message: " + text);
    // Simulate non-trivial business process that takes ~10
    seconds.
    Thread.currentThread().sleep(10000);
    }catch(Exception e){
    e.printStackTrace();
    Now I have a little test application that throws ten messages into the
    queue. Each message is consumed from the queue SEQUENTIALLY which is
    not my understanding of concurrent processing. So in all sending ten
    messages to the queue each message is processed in turn taking 100 seconds
    for the whole thing to complete instead of 10 MDB instances all chewing on
    a different message and the whole thing would complete in roughly 10
    seconds.
    Is there a setup step that I have missed? I have bumped the
    default.properties file messagebean.pool.size=30 from its default of 3.
    It does create 10 bean instances, what for I don't know...
    Thanks
    Steve

    Message beans are used for asynchronous calls, meaning that the container decides in what order to execute them. If you want to achieve concurrent calls consider using Session Beans.
    Regards,
    Dimitar

Maybe you are looking for