TransactionRolledbackLocalException in JMS messaging application

Hi, I have a message driven bean (MDB) that gives the following error and I'm unable to resolve it. Any help would be appreciated. Thanks.
[1/18/06 15:17:44:977 PST] 7d9913e7 SystemOut O Exception occurred inside AppLogMDBean: java.lang.NullPointerException
[1/18/06 15:17:44:986 PST] 7d9913e7 ServerSession W WMSG0031E: Exception processing JMS Message for MDB AppLogReceiverMDB, JMS
Destination jms/appLogQueue : javax.ejb.TransactionRolledbackLocalException: ; nested exception is: com.ibm.ws.exception.WsEJ
BException
com.ibm.ws.exception.WsEJBException
at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapException(LocalExceptionMappingStrategy.java(Compiled Code))
at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSITransactionRolledBackException(LocalExceptionMappingStrat
egy.java(Compiled Code))
at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java(Compiled Code))
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java(Compiled Code))
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java(Compiled Code))
at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java(Compiled Code))
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java(Compiled Code))
javax.ejb.TransactionRolledbackLocalException: ; nested exception is: com.ibm.ws.exception.WsEJBException
at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSIException(LocalExceptionMappingStrategy.java(Compiled Cod
e))
at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapException(LocalExceptionMappingStrategy.java(Compiled Code))
at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSITransactionRolledBackException(LocalExceptionMappingStrat
egy.java(Compiled Code))
at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java(Compiled Code))
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java(Compiled Code))
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java(Compiled Code))
at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java(Compiled Code))
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java(Compiled Code))
this is the code for the onMessage function of the bean
public void onMessage(javax.jms.Message msg)
          int executeStatus          = -1;
          Connection con               = null;
          DataSource ds               = null;
          String dataSourceName     = null;
          PreparedStatement stmt     = null;
          MapMessage mapMessage     = null;
          String sqlStatement          = null;
          Properties properties;
          CommonPropertiesHelper propertyHelper;
          try{
               mapMessage = (MapMessage)msg;
               propertyHelper = CommonPropertiesHelper.getInstance("EGOVJournal.properties");
               properties = propertyHelper.getProperties();
               sqlStatement = properties.getProperty("INSERT_VIRR052U_APP_LOG");
               dataSourceName = properties.getProperty("DATA_SOURCE");
               if ( (sqlStatement != null) && (dataSourceName != null)){
                    UserTransaction transaction = fMessageDrivenCtx.getUserTransaction();
                    transaction.begin();
                    javax.naming.InitialContext ctx = new javax.naming.InitialContext();
                    ds = (javax.sql.DataSource) ctx.lookup(dataSourceName);
                    con = ds.getConnection();
                    if (con != null){
                         int x = 1;
                         stmt = con.prepareStatement(sqlStatement);
                         String logId     = mapMessage.getString("LOG_ID");
                         if (logId.length() > 40)
                              logId = logId.substring(0,39);
                         String jnlId     = mapMessage.getString("JOURNAL_ID");
                         if (jnlId.length() > 40)
                              jnlId = jnlId.substring(0,39);
                         String appName     = mapMessage.getString("APPLICATION_NAME");
                         if (appName.length() > 30)
                              appName = appName.substring(0,29);
                         String logLevel     = mapMessage.getString("LOGGING_LEVEL");
                         if (logLevel.length() > 2)
                              logLevel = logLevel.substring(0,1);
                         String msgName     = mapMessage.getString("MESSAGE_NAME");
                         if(msgName.length() > 100)
                              msgName = msgName.substring(0,99);
                         String msgDesc     = mapMessage.getString("MESSAGE_DESCRIPTION");
                         if (msgDesc.length() > 1800)
                              msgDesc = msgDesc.substring(0,1799);
                         stmt.setObject(x,logId);
                         x++;
                         stmt.setObject(x,jnlId);
                         x++;
                         stmt.setObject(x,appName);
                         x++;
                         stmt.setObject(x,logLevel);
                         x++;
                         stmt.setObject(x,msgName);
                         x++;
                         stmt.setObject(x,msgDesc);
                         x++;
                         // Execute the Prepared Statement
                         executeStatus = stmt.executeUpdate();
                         stmt.close();
                         con.close();
                         transaction.commit();
                    else{
                         System.out.println("Connection is null inside AppLogMDBean");
               else{
                    System.out.println("Either sql or dataSource is null inside AppLogMDBean. Can't continue.");
          catch(NamingException e){
               System.out.println("NamingException occurred inside AppLogMDBean: " + e);
          catch(JMSException e){
               System.out.println("JMSException occurred inside AppLogMDBean: " + e);
          catch(Exception e){
               System.out.println("Exception occurred inside AppLogMDBean: " + e);
          finally{
               try{
                    if(stmt!=null){
                         stmt.close();
                         stmt = null;
                    if(con != null){
                         con.close();
                         con = null;
               catch(Exception e){
                    System.out.println("Exception occurred inside AppLogMDBean in finally block : " + e);
     }

Hi, I have a message driven bean (MDB) that gives the following error and I'm unable to resolve it. Any help would be appreciated. Thanks.
[1/18/06 15:17:44:977 PST] 7d9913e7 SystemOut O Exception occurred inside AppLogMDBean: java.lang.NullPointerException
[1/18/06 15:17:44:986 PST] 7d9913e7 ServerSession W WMSG0031E: Exception processing JMS Message for MDB AppLogReceiverMDB, JMS
Destination jms/appLogQueue : javax.ejb.TransactionRolledbackLocalException: ; nested exception is: com.ibm.ws.exception.WsEJ
BException
com.ibm.ws.exception.WsEJBException
at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapException(LocalExceptionMappingStrategy.java(Compiled Code))
at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSITransactionRolledBackException(LocalExceptionMappingStrat
egy.java(Compiled Code))
at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java(Compiled Code))
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java(Compiled Code))
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java(Compiled Code))
at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java(Compiled Code))
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java(Compiled Code))
javax.ejb.TransactionRolledbackLocalException: ; nested exception is: com.ibm.ws.exception.WsEJBException
at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSIException(LocalExceptionMappingStrategy.java(Compiled Cod
e))
at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapException(LocalExceptionMappingStrategy.java(Compiled Code))
at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSITransactionRolledBackException(LocalExceptionMappingStrat
egy.java(Compiled Code))
at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java(Compiled Code))
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java(Compiled Code))
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java(Compiled Code))
at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java(Compiled Code))
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java(Compiled Code))
this is the code for the onMessage function of the bean
public void onMessage(javax.jms.Message msg)
          int executeStatus          = -1;
          Connection con               = null;
          DataSource ds               = null;
          String dataSourceName     = null;
          PreparedStatement stmt     = null;
          MapMessage mapMessage     = null;
          String sqlStatement          = null;
          Properties properties;
          CommonPropertiesHelper propertyHelper;
          try{
               mapMessage = (MapMessage)msg;
               propertyHelper = CommonPropertiesHelper.getInstance("EGOVJournal.properties");
               properties = propertyHelper.getProperties();
               sqlStatement = properties.getProperty("INSERT_VIRR052U_APP_LOG");
               dataSourceName = properties.getProperty("DATA_SOURCE");
               if ( (sqlStatement != null) && (dataSourceName != null)){
                    UserTransaction transaction = fMessageDrivenCtx.getUserTransaction();
                    transaction.begin();
                    javax.naming.InitialContext ctx = new javax.naming.InitialContext();
                    ds = (javax.sql.DataSource) ctx.lookup(dataSourceName);
                    con = ds.getConnection();
                    if (con != null){
                         int x = 1;
                         stmt = con.prepareStatement(sqlStatement);
                         String logId     = mapMessage.getString("LOG_ID");
                         if (logId.length() > 40)
                              logId = logId.substring(0,39);
                         String jnlId     = mapMessage.getString("JOURNAL_ID");
                         if (jnlId.length() > 40)
                              jnlId = jnlId.substring(0,39);
                         String appName     = mapMessage.getString("APPLICATION_NAME");
                         if (appName.length() > 30)
                              appName = appName.substring(0,29);
                         String logLevel     = mapMessage.getString("LOGGING_LEVEL");
                         if (logLevel.length() > 2)
                              logLevel = logLevel.substring(0,1);
                         String msgName     = mapMessage.getString("MESSAGE_NAME");
                         if(msgName.length() > 100)
                              msgName = msgName.substring(0,99);
                         String msgDesc     = mapMessage.getString("MESSAGE_DESCRIPTION");
                         if (msgDesc.length() > 1800)
                              msgDesc = msgDesc.substring(0,1799);
                         stmt.setObject(x,logId);
                         x++;
                         stmt.setObject(x,jnlId);
                         x++;
                         stmt.setObject(x,appName);
                         x++;
                         stmt.setObject(x,logLevel);
                         x++;
                         stmt.setObject(x,msgName);
                         x++;
                         stmt.setObject(x,msgDesc);
                         x++;
                         // Execute the Prepared Statement
                         executeStatus = stmt.executeUpdate();
                         stmt.close();
                         con.close();
                         transaction.commit();
                    else{
                         System.out.println("Connection is null inside AppLogMDBean");
               else{
                    System.out.println("Either sql or dataSource is null inside AppLogMDBean. Can't continue.");
          catch(NamingException e){
               System.out.println("NamingException occurred inside AppLogMDBean: " + e);
          catch(JMSException e){
               System.out.println("JMSException occurred inside AppLogMDBean: " + e);
          catch(Exception e){
               System.out.println("Exception occurred inside AppLogMDBean: " + e);
          finally{
               try{
                    if(stmt!=null){
                         stmt.close();
                         stmt = null;
                    if(con != null){
                         con.close();
                         con = null;
               catch(Exception e){
                    System.out.println("Exception occurred inside AppLogMDBean in finally block : " + e);
     }

Similar Messages

  • I am unable to send JMS message to application which resides in third party

    I am able to produce the Message into JMS demoQueue which is available in SOA 10.1.3.3. And also I tried remote server which is available in my office it having the application SchoolMAX with JMS Configuration. So I need to produce the JMS message into SchoolMAX application. But I am unable to pass to the data’s to that SchoolMAX JMS.
    for this I have configured the respective queues, queue factory etc in Enterprise Manager , but i am not able to access our application which is in remote server through third party in JDeveloper for BPEL Process.
    please i am very new to this JDeveloper & BPEL Console , please help me out in resolving the issue ASAP. please we will be waiting for some reply.

    Hi Kathy,
    Happy Holidays!  Do you have an iPad with cellular service and a text-messaging plan?
    Send messages with your iPhone, iPad, or iPod touch - Apple Support
    http://support.apple.com/en-us/HT201287
    What's the difference between SMS/MMS and iMessage?
    SMS/MMS lets you send text messages and photos to other cellular phones or devices. iMessage lets you send text messages and photos to another iOS device over Wi-Fi, without worrying about text-messaging charges (cellular data charges may apply). 
    What do I need to use SMS/MMS and iMessage?
    Here's what you need to use SMS/MMS and iMessage:
    SMS/MMS: A text-messaging plan. Contact your carrier for more information.
    iMessage: An iPhone, iPad, or iPod touch with iOS 5 or later.
    How do I know if my message used SMS/MMS or iMessage?
    You can tell which type of message you're sending by the color of the Send button and text bubble.
    SMS/MMS: Send button and text bubbles are green.
    iMessage: Send button and text bubbles are blue.
    How can I link my iPhone number with Messages on my iPad, iPod touch, or Messages for Mac?
    When you sign in to Messages with your Apple ID on your iPhone, you link your phone number to your Apple ID. If you then sign in to Messages with the same Apple ID on your iPad, iPod touch, or Mac, Messages will link that device to your phone number as well.
    I hope this information helps ....
    - Judy

  • TransactionRolledbackLocalException in JMS Embedded Messaging...

    We"re using two Message Driven Beans (say MDB1 and MDB2) and two EJBs (say EJB1 and EJB2) in a module in our project to implement JMS Embedded messaging on WAS5.1 (using WSAD5.1.2 environment)
    The MDB2"s onMessage() listens to a queue written by EJB1 and MDB1"s onMessage() also listens to a queue written by EJB1.
    Flow:-
    EJB1 starts first and writes a queue to the MDB2, which asynchronously invokes the EJB2 and this EJB2, after calls to a few utility classes invokes EJB1. Then, EJB1, with the Vector input from EJB2 writes a queue to be captured by MDB1.
    The first flow of EJB1 --> MDB2 works fine, but the second part (EJB1 --> MDB1) is failing and the MDB2 is also getting shut down because of this. The cause of this is a <b>javax.ejb.TransactionRolledbackLocalException: ; nested exception is: com.ibm.ws.exception.WsEJBException</b>
    Can someone who"s already faced such a challege kindly help?
    This is the stack trace:- (for sake of clarity, MSSPriceChangeAlertMDB in the below trace is the MDB2)
    [8/9/05 19:55:11:951 EDT] 234d1b6e RegisteredRes E WTRN0063E: An illegal attempt to commit a one phase capable resource with existing two phase capable resources has occurred.
    [8/9/05 19:55:14:467 EDT] 2a50db6e JMSExceptionL E WMSG0018E: Error on JMSConnection for MDB MSSPriceChangeAlertMDB , JMSDestination jms/MarketDataQueue : javax.jms.JMSException: MQJMS1016: an internal error has occurred. Please contact your system administrator. Detail: {0}
    at com.ibm.mq.jms.services.ConfigEnvironment.newException(ConfigEnvironment.java:540)
    at com.ibm.mq.jms.MQQueueAgentThread.run(MQQueueAgentThread.java:1583)
    at java.lang.Thread.run(Thread.java:568)
    ---- Begin backtrace for Nested Throwables
    java.lang.NullPointerException
    at com.ibm.mq.jms.MQQueueAgentThread.processMessage(MQQueueAgentThread.java:368)
    at com.ibm.mq.jms.MQQueueAgentThread.run(MQQueueAgentThread.java:1557)
    at java.lang.Thread.run(Thread.java:568)
    [8/9/05 19:55:14:576 EDT] 2a50db6e JMSExceptionL E WMSG0057E: Error on JMSConnection for MDB MSSPriceChangeAlertMDB , JMSDestination jms/MarketDataQueue , JMS Linked Exception : java.lang.NullPointerException
    at com.ibm.mq.jms.MQQueueAgentThread.processMessage(MQQueueAgentThread.java:368)
    at com.ibm.mq.jms.MQQueueAgentThread.run(MQQueueAgentThread.java:1557)
    at java.lang.Thread.run(Thread.java:568)
    [8/9/05 19:55:14:654 EDT] 2a50db6e MDBListenerIm I WMSG0043I: MDB Listener MarketDataAlertListener stopped for JMSDestination jms/MarketDataQueue
    [8/9/05 19:55:14:982 EDT] 234d1b6e ServerSession W WMSG0031E: Exception processing JMS Message for MDB MSSPriceChangeAlertMDB, JMSDestination jms/MarketDataQueue : javax.ejb.TransactionRolledbackLocalException: ; nested exception is: com.ibm.ws.exception.WsEJBException
    com.ibm.ws.exception.WsEJBException
    at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapException(LocalExceptionMappingStrategy.java:159)
    at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSITransactionRolledBackException(LocalExceptionMappingStrategy.java:293)
    at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java:3128)
    at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:102)
    at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:127)
    at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java:372)
    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:672)
    javax.ejb.TransactionRolledbackLocalException: ; nested exception is: com.ibm.ws.exception.WsEJBException
    at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSIException(LocalExceptionMappingStrategy.java:96)
    at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapException(LocalExceptionMappingStrategy.java:165)
    at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSITransactionRolledBackException(LocalExceptionMappingStrategy.java:293)
    at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java:3128)
    at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:102)
    at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:127)
    at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java:372)
    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:672)
    Thanks a ton in advance!

    hi
    I am using two MDb nad about 5 Ejb's..thw transaction attribute for the MDB are set to Required..and for the EjB it is set to Not Supported.Moreover i am using a CLi datasource...but i am getting this error:::::
    ServerSession W WMSG0031E: Exception processing JMS Message for MDB AggregatedMT598PosnSwiftReader, JMSDestination jms/accounting/ACCT.MT598_535.CORR.OUT.QUEUE : javax.ejb.TransactionRolledbackLocalException: ; nested exception is: com.ibm.ws.exception.WsEJBException
    com.ibm.ws.exception.WsEJBException
         at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapException(LocalExceptionMappingStrategy.java:159)
         at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSITransactionRolledBackException(LocalExceptionMappingStrategy.java:293)
         at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java:3159)
         at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:102)
         at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:127)
         at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java:375)
         at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:936)
    javax.ejb.TransactionRolledbackLocalException: ; nested exception is: com.ibm.ws.exception.WsEJBException
         at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSIException(LocalExceptionMappingStrategy.java:96)
         at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapException(LocalExceptionMappingStrategy.java:165)
         at com.ibm.ejs.container.LocalExceptionMappingStrategy.mapCSITransactionRolledBackException(LocalExceptionMappingStrategy.java:293)
         at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java:3159)
         at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:102)
         at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:127)
         at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java:375)
         at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:936)
    PLz help..its kind of urgent

  • JMS message from one application to the another appl in the same container?

    I have a question.
    Can I send JMS message from one application to the another application in the same container?
    If yes ...can you provide me info.
    I want to know in regards of EJB2.0 and EJB3.0.
    Thanks,
    Rahul

    So the receiver application is a Message Driven Bean, right?
    In your container, do you have a mean to ensure that it is correctly configured to listen the desired destination? Like an administrative console that would show the destinations, the number of pending messages, the number of active consummers...?
    btw what is the destination type? A queue or a topic?

  • Need suggestion on  implementing JMS message error recovery

    Hi,
    Our application has a JMS topic where we publish application events. Now, there can be scenarios where the consumers cannot process the message due to some infrastructure issues and would error out. We need a way so that those messages can be reprocessed again later. we are thinking of the following design for JMS message error recovery
    1. Use a persistent TOPIC (this would ensure guaranteed delivery)
    2. Configure a error destination on JMS topic e.g a jms queue
    3. Have an error handling MDB listening to the Error destination. An error handling MDB would dequeue the errored messages from error destination and persist it to a Data base "error" table..
    4. Provide a mechanism to republish those messages to topic (e.g a scheduler or admin ui or a command line utility) .. The messages would deleted from database "error" table and published to topic again....
    A. Are there any issues with the above design which we need to handle?
    B. Are there any additional steps required in a Cluster environment with a distributed topic and distribute error destination? (our error mdb will have one-copy-per-application setting)
    B. From a performance angle, Is it OK to use persistent TOPIC ? Or will it better to persist the message to the db table and then publish it as a non persistent message ... ? (But i guess the performance should be more or less the same in both of these approaches)
    C. Are there any other recommended design patterns for error recovery of JMS messages
    Please advise.
    Regards,
    Arif

    Thanks Tom !
    We may not be able to go with the approach of delaying/pausing redelivery of the messsage because
    1. Pausing entire MDB approach: Our MDB application consumes messages generated by different producers and our MDB needs to continue processing the messages even if messages corresponding to one producer is erroring out
    2. Redelivery delay : This would only delay the retry of an errored message. But there would still be a problem if the message fails during all retries (i.e redelivery limit count). We don't want to lose this message. In our case, It is possible that a particular message cannot be processed due to unavailability of a third party system for hours or may be a day.
    Basically, i am looking on approaches for a robust and performant error recovery/retry framework for our application (refer details in my first post on this thread) while fully making use of all features provided by middleware (WLS). Please advise.
    Regards,
    Arif

  • Problem in sending JMS message on remote OC4J

    I have two OC4J standalone (10.1.3.0.0 build 041119.0001.2385)
    The containers work on Windows2000 in different machines connected by the LAN.
    The First container has deployed application from example http://www.oracle.com/technology/tech/java/oc4j/1013/howtos/how-to-jca-intro/doc/how-to-jca-intro.html
    The second container has j2ee application (Servlet) that sending JMS messages in the queue of the first container.
    Code Servlet in second OC4J:
    package mypackage2;
    import javax.servlet. *;
    import javax.servlet.http. *;
    import java.io. PrintWriter;
    import java.io. IOException;
    import javax.jms. *;
    import javax.naming. *;
    import java.util. *;
    public class Servlet1 extends HttpServlet
    private static final String CONTENT_TYPE = "text/html;charset=windows-1251";
    public void init (ServletConfig config) throws ServletException
    super.init (config);
    String QUEUE_NAME = "OracleASjms/MyQueue1";
    String QUEUE_CONNECTION_FACTORY = "OracleASjms/MyQCF";
    public void doGet (HttpServletRequest request, HttpServletResponse response)
    throws ServletException, IOException
    response.setContentType (CONTENT_TYPE);
    PrintWriter out = response.getWriter ();
    out.println (" < html > ");
    out.println (" < head > < title > Servlet1 < /title > < /head > ");
    out.println (" < body > ");
    try
    Hashtable env = new Hashtable ();
    env.put (Context. INITIAL_CONTEXT_FACTORY, "oracle.j2ee.rmi.RMIInitialContextFactory");
    env.put (Context. SECURITY_PRINCIPAL, "admin");
    env.put (Context. SECURITY_CREDENTIALS, "admin");
    env.put (Context. PROVIDER_URL, "ormi://host_OC4J_1:23791/jcamdb");
    env.put ("dedicated.rmicontext", "true");
    InitialContext ic = new InitialContext (env);
    QueueConnectionFactory connectionFactory = (QueueConnectionFactory)ic.lookup (QUEUE_CONNECTION_FACTORY);
    QueueConnection connection = connectionFactory.createQueueConnection ();
    connection.start ();
    QueueSession queueSession =
    connection.createQueueSession (false, Session.AUTO_ACKNOWLEDGE);
    Queue queue = (Queue) ic.lookup (QUEUE_NAME);
    ic.close ();
    System.out.println (" Queue: " + queue);
    QueueSender sender = queueSession.createSender (queue);
    System.out.println (" creating Message: " + queue);
    Message message = queueSession.createMessage ();
    System.out.println (" Message created ");
    message.setJMSType ("theMessage");
    message.setLongProperty ("time", System.currentTimeMillis ());
    message.setStringProperty ("id", "11111");
    message.setStringProperty ("oamount", "55555");
    message.setStringProperty ("message", "77777");
    message.setStringProperty ("RECIPIENT", "MDB");
    System.out.println (" Sending message... ");
    sender.send (message);
    System.out.println (" Message sent ");
    sender.close ();
    queueSession.close ();
    connection.close ();
    catch (Exception e)
    System.out.println (" ** TEST FAILED ** < br > Exception: " + e);
    out.println (e.toString ());
    e.printStackTrace ();
    out.println (" < p > The servlet has received a GET. This is the reply. < /p
    ");out.println (" < /body > < /html > ");
    out.close ();
    Error: This code send message in The First container, and should send in the second OC4J !!!!
    Please answer :
    As configure (what code it is necessary to write) servlet (any J2EE the application in OC4J) to use a path to OC4J JMS (remote OC4J JMS) through the Resource Adapter (using OracleASjms.rar). ???

    I have two OC4J standalone (10.1.3.0.0 build 041119.0001.2385)
    The containers work on Windows2000 in different machines connected by the LAN.
    The First container has deployed application from example http://www.oracle.com/technology/tech/java/oc4j/1013/howtos/how-to-jca-intro/doc/how-to-jca-intro.html
    The second container has j2ee application (Servlet) that sending JMS messages in the queue of the first container.
    Code Servlet in second OC4J:
    package mypackage2;
    import javax.servlet. *;
    import javax.servlet.http. *;
    import java.io. PrintWriter;
    import java.io. IOException;
    import javax.jms. *;
    import javax.naming. *;
    import java.util. *;
    public class Servlet1 extends HttpServlet
    private static final String CONTENT_TYPE = "text/html;charset=windows-1251";
    public void init (ServletConfig config) throws ServletException
    super.init (config);
    String QUEUE_NAME = "OracleASjms/MyQueue1";
    String QUEUE_CONNECTION_FACTORY = "OracleASjms/MyQCF";
    public void doGet (HttpServletRequest request, HttpServletResponse response)
    throws ServletException, IOException
    response.setContentType (CONTENT_TYPE);
    PrintWriter out = response.getWriter ();
    out.println (" < html > ");
    out.println (" < head > < title > Servlet1 < /title > < /head > ");
    out.println (" < body > ");
    try
    Hashtable env = new Hashtable ();
    env.put (Context. INITIAL_CONTEXT_FACTORY, "oracle.j2ee.rmi.RMIInitialContextFactory");
    env.put (Context. SECURITY_PRINCIPAL, "admin");
    env.put (Context. SECURITY_CREDENTIALS, "admin");
    env.put (Context. PROVIDER_URL, "ormi://host_OC4J_1:23791/jcamdb");
    env.put ("dedicated.rmicontext", "true");
    InitialContext ic = new InitialContext (env);
    QueueConnectionFactory connectionFactory = (QueueConnectionFactory)ic.lookup (QUEUE_CONNECTION_FACTORY);
    QueueConnection connection = connectionFactory.createQueueConnection ();
    connection.start ();
    QueueSession queueSession =
    connection.createQueueSession (false, Session.AUTO_ACKNOWLEDGE);
    Queue queue = (Queue) ic.lookup (QUEUE_NAME);
    ic.close ();
    System.out.println (" Queue: " + queue);
    QueueSender sender = queueSession.createSender (queue);
    System.out.println (" creating Message: " + queue);
    Message message = queueSession.createMessage ();
    System.out.println (" Message created ");
    message.setJMSType ("theMessage");
    message.setLongProperty ("time", System.currentTimeMillis ());
    message.setStringProperty ("id", "11111");
    message.setStringProperty ("oamount", "55555");
    message.setStringProperty ("message", "77777");
    message.setStringProperty ("RECIPIENT", "MDB");
    System.out.println (" Sending message... ");
    sender.send (message);
    System.out.println (" Message sent ");
    sender.close ();
    queueSession.close ();
    connection.close ();
    catch (Exception e)
    System.out.println (" ** TEST FAILED ** < br > Exception: " + e);
    out.println (e.toString ());
    e.printStackTrace ();
    out.println (" < p > The servlet has received a GET. This is the reply. < /p
    ");out.println (" < /body > < /html > ");
    out.close ();
    Error: This code send message in The First container, and should send in the second OC4J !!!!
    Please answer :
    As configure (what code it is necessary to write) servlet (any J2EE the application in OC4J) to use a path to OC4J JMS (remote OC4J JMS) through the Resource Adapter (using OracleASjms.rar). ???

  • How to stop and start MDBs to listen for JMS messages

    Hello! This might be more of an architecture question rather than a technical questing, but I post it here, in the lack of a better place...
    For several years I have been using Webster and Webster MQ to send messages back and forth to clients. The architecture for the middleware platform has been designed around the functionality of ListenerPorts. Listenerports is a Webster functionality that let you "stop" and start to listen to JMS messages for a given MDB either by admin console, or by JMX.
    The arhitecture we used was something like this :
    1.Client sends a persistent message to a queue. (order)
    2. An MDB pics up the order message, calls a SessionBean that "fronts" the IIOP back end system.
    This is quite "out of the box" architecture, but we used the Listenerports to solve a stability problem for our back end system.
    The backEnd system was quite unstable, so the EJB threw an exception (typically because of timeout or connection refused) back to the MDB.
    The Listenerport was "defined" to handle 3 errors before stopping, so the MDB resent the message twice before the listenerport automatically stopped. The nice thing about this feature was that the client could continue to send orders, and was not bothered when the back end system was down.
    When the backEnd system was up and running, we could start the listenerport and it was all back to normal state. We even had a start script that checked the state of the listenerport every 30 minute, and started it automatically if it was stopped, making the admin task of starting the MDB unnecessary..
    Now.. Why am I telling this story..
    I would like to know how this could be done using "clean" J2EE technologies..That is..Not using any technology that is not portable..
    I`m playing with glassfish at home, and it struck me that there is nothing in the J2EE spec that defines the functionality described above ? Am i missing something ?
    I Do not want to stop My application because the back end system is down? That is the only way (i know of) that i can "stop" to listen for messages..
    I can put all the messages on an error queue when the backbend system is down, but that would lead to more code just to handle the error messages. Maybe the easiest way to solve this is to "move" (programmatically) all messages from the error queue over to the "standard" queue every XX minute, but somehow that sounds "wrong"
    Can anyone give me some advice to how this problem situation should be solved ? I`m interested in the solution both from an architectural perspective and from a more technical perspective..
    Best regards
    Hans-Jacob Melby

    Breakpoints, whether normal or conditional, are just meant for debugging of your code.  I had the sense from your question that the pausing you want to do is a part of normal operation of your code.  I would NOT recommend using a breakpoint for that situation.  It would bring up the block diagram showing the breakpoint when it occurs.  A user besides the programmer would not know what to do in that case.
     Yes, both the inner and outer loops would have shift registers.
    Putting a case structure with a small while loop inside the "Pausing Case" is doable.  It just depends on what you are doing or waiting for while the program operation is "paused".

  • Adapter Status Error :  Error in creating message ID map for JMS message:

    Currently in the SAP XI 3.0 JMS Adapter, I am receiving the following error
    Error in creating message ID map for JMS message:
    ie. Error while processing message 'de8265f6-c864-4479-1137-9bab17b78b3b';  detailed error description: com.sap.aii.adapter.jms.api.channel.filter.MessageFilterException: Error in creating message ID map for JMS message: ID:c3e2d840d8d4d7f14040404040404040c44f8e2213630b01 at com.sap.aii.adapter.jms.core.channel.filter.InboundDuplicateCheckFilter.filter(InboundDuplicateCheckFilter.java:103)
    Although I am receivng this error, when I check the details of the message processing, all steps are successful and the message is set to status : DLVD
    Audit Log for Message: de8265f6-c864-4479-1137-9bab17b78b3b
    Time Stamp     Status     Description
    09.06.2009 13:27:24     Success     New JMS message with JMS message ID ID:c3e2d840d8d4d7f14040404040404040c44f8e2213630b01 received. The XI message ID for this message is de8265f6-c864-4479-1137-9bab17b78b3b
    09.06.2009 13:27:24     Success     JMS message converted to XI message format successfully
    09.06.2009 13:27:24     Success     RRB: entering RequestResponseBean
    09.06.2009 13:27:24     Success     RRB: suspending the transaction
    09.06.2009 13:27:24     Success     RRB: passing through ...
    09.06.2009 13:27:24     Success     RRB: leaving RequestResponseBean
    09.06.2009 13:27:24     Success     Transform: using Transform.Class: com.sap.aii.messaging.adapter.Conversion
    09.06.2009 13:27:24     Success     Transform: transforming the payload ...
    09.06.2009 13:27:24     Success     Transform: successfully transformed
    09.06.2009 13:27:24     Success     Application attempting to send an XI message synchronously using connection JMS_http://sap.com/xi/XI/System.
    09.06.2009 13:27:24     Success     Trying to put the message into the call queue.
    09.06.2009 13:27:24     Success     Message successfully put into the queue.
    09.06.2009 13:27:24     Success     The message was successfully retrieved from the call queue.
    09.06.2009 13:27:24     Success     The message status set to DLNG.
    09.06.2009 13:27:25     Success     The application sent the message synchronously using connection JMS_http://sap.com/xi/XI/System. Returning to application.
    09.06.2009 13:27:25     Success     The message was successfully transmitted to endpoint http://sapxia.swets.nl:8000/sap/xi/engine?type=entry using connection JMS_http://sap.com/xi/XI/System.
    09.06.2009 13:27:25     Success     The message status set to DLVD.
    Not sure why this is occurring.......

    No, not using correlation id.
    I was able to resolve the issue on this queue by changing the following setting
    Under the PROCESSING tab, under XI SETTINGS
    Time period for Duplicate Check for EO(IO) (secs) it was set to 86400
    I have changed this to 300 seconds and the adapter has now gone green.
    BUT......
    That said, I have the exact scenario on another sender JMS channel set to 300 seconds and it exhibits the same issue.
    correlation settings:
    Set XI message id  to  = GUID
    Set Xi conversation

  • JMS Messages getting stuck in queues

    Hi,
    I am facing this peculiar issue with queue messages not getting picked up.
    Application Architecture: There is 1 JMS queue ( which resides in WLDomain1 with in a Unix Box) and there are 2 windows boxes having 2 weblogic domains each with 3 instances of MDB deployed on each of the domains. So total of 12 consumers (2 Box * 2 Domain * 3 Instances of MDB) listens to the JMS queue.
    Issue: After bringing everything up I am able to see 12 consumer count listening to the queue. But when I run the application which writes total of 13 messages in the queue only 7 of them are getting processed and 6 messages are always getting stuck in the queues. Interestingly this 7 messages are mostly getting processed by consumers with in the same windows box. And the selection of windows box is completely random. To confirm whether both the windows boxes are configured fine I tried to test them individually and it works fine individually, the problem happens only if I bring up both the boxes together.
    Another observation is, if I bring down the non working domains, the pending messages start getting processed by the working domains. It gives an impression that the non working domains seem to lock the messages for processing but doesn't actually process it. Only when I bring down the domains it releases this lock.
    Below is the JMS Life cycle events I captured from log files :
    1. Start domain1 in WIN Box1
    ####<Nov 24, 2009 7:54:00 PM CST> <> <> <1259114040304> <783400> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection59.session60.consumer62)> <> <>
    ####<Nov 24, 2009 7:54:00 PM CST> <> <> <1259114040309> <239900> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection59.session63.consumer65)> <> <>
    ####<Nov 24, 2009 7:54:00 PM CST> <> <> <1259114040313> <2100> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection59.session66.consumer68)> <> <>
    2. Start domain2 in WIN Box 1
    ####<Nov 24, 2009 7:54:55 PM CST> <> <> <1259114095403> <38600> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection69.session70.consumer72)> <> <>
    ####<Nov 24, 2009 7:54:55 PM CST> <> <> <1259114095407> <335400> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection69.session73.consumer75)> <> <>
    ####<Nov 24, 2009 7:54:55 PM CST> <> <> <1259114095410> <997700> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection69.session76.consumer78)> <> <>
    3. Start domain1 in WIN Box 2
    ####<Nov 24, 2009 7:56:12 PM CST> <> <> <1259114172061> <316500> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection79.session80.consumer82)> <> <>
    ####<Nov 24, 2009 7:56:12 PM CST> <> <> <1259114172066> <324300> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection79.session83.consumer85)> <> <>
    ####<Nov 24, 2009 7:56:12 PM CST> <> <> <1259114172072> <757000> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection79.session86.consumer88)> <> <>
    4. Start domain2 in WIN Box 2
    ####<Nov 24, 2009 7:56:54 PM CST> <> <> <1259114214000> <142800> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection89.session90.consumer92)> <> <>
    ####<Nov 24, 2009 7:56:54 PM CST> <> <> <1259114214005> <38200> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection89.session93.consumer95)> <> <>
    ####<Nov 24, 2009 7:56:54 PM CST> <> <> <1259114214009> <22400> <> <> <JMSModule!Queue> <ConsumerCreate> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection89.session96.consumer98)> <> <>
    At this point console shows 12 consumers listening the queue which is absolutely fine.
    5. Run application
    --Message Production
    This produces 13 messages ( I have not pasted the complete log)
    -- Message Consumption ( Only 7 messages are consumed)
    ####<Nov 24, 2009 8:00:05 PM CST> <> <> <1259114405953> <576400> <ID:<1047832.1259114392542.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection59.session63.consumer65)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114392542&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    ####<Nov 24, 2009 8:00:10 PM CST> <> <> <1259114410091> <310100> <ID:<1047832.1259114393181.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection59.session66.consumer68)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114393181&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    ####<Nov 24, 2009 8:00:10 PM CST> <> <> <1259114410130> <364600> <ID:<1047832.1259114400626.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection59.session63.consumer65)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114400626&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    ####<Nov 24, 2009 8:00:10 PM CST> <> <> <1259114410134> <540700> <ID:<1047832.1259114393125.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection69.session76.consumer78)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114393125&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    ####<Nov 24, 2009 8:00:10 PM CST> <> <> <1259114410137> <632400> <ID:<1047832.1259114393128.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection69.session73.consumer75)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114393128&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    ####<Nov 24, 2009 8:00:12 PM CST> <> <> <1259114412026> <984200> <ID:<1047832.1259114393123.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection59.session60.consumer62)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114393123&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    ####<Nov 24, 2009 8:00:16 PM CST> <> <> <1259114416045> <41800> <ID:<1047832.1259114400005.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection69.session70.consumer72)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114400005&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    6. At this point Admin Consol shows 6 messages pending in the queue
    and From consumer numbers it is evident that consumers in WIN Box2 domains have not processed any messages
    Now if I stop server in WIN Box2 Domain1, WIN Box1 picks up the messages instantely
    ####<Nov 24, 2009 8:13:22 PM CST> <> <> <1259115202343> <897600> <> <> <JMSModule!Queue> <ConsumerDestroy> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection79.session80.consumer82)> <> <>
    ####<Nov 24, 2009 8:13:22 PM CST> <> <> <1259115202346> <421900> <> <> <JMSModule!Queue> <ConsumerDestroy> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection79.session83.consumer85)> <> <>
    ####<Nov 24, 2009 8:13:22 PM CST> <> <> <1259115202379> <582300> <> <> <JMSModule!Queue> <ConsumerDestroy> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection79.session86.consumer88)> <> <>
    ####<Nov 24, 2009 8:13:24 PM CST> <> <> <1259115204888> <4600> <ID:<1047832.1259114400029.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection69.session76.consumer78)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114400029&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    ####<Nov 24, 2009 8:13:32 PM CST> <> <> <1259115212820> <256700> <ID:<1047832.1259114400258.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection59.session66.consumer68)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114400258&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    ####<Nov 24, 2009 8:13:43 PM CST> <> <> <1259115223579> <280600> <ID:<1047832.1259114400032.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection59.session60.consumer62)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114400032&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    7. At this poing Admin Consol shows 3 messages pending in the queue
    Now if I stop server in WIN Box2 Domain2, the remaining 3 gets processed
    ####<Nov 24, 2009 8:16:08 PM CST> <> <> <1259115368998> <193400> <> <> <JMSModule!Queue> <ConsumerDestroy> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection89.session90.consumer92)> <> <>
    ####<Nov 24, 2009 8:16:08 PM CST> <> <> <1259115369000> <885500> <> <> <JMSModule!Queue> <ConsumerDestroy> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection89.session93.consumer95)> <> <>
    ####<Nov 24, 2009 8:16:09 PM CST> <> <> <1259115369002> <902500> <> <> <JMSModule!Queue> <ConsumerDestroy> <<anonymous>> <MC:CA(/<IP_BOX2>):OAMI(server.jms.connection89.session96.consumer98)> <> <>
    ####<Nov 24, 2009 8:16:25 PM CST> <> <> <1259115385151> <123700> <ID:<1047832.1259114400324.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection69.session70.consumer72)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114400324&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    ####<Nov 24, 2009 8:16:29 PM CST> <> <> <1259115389660> <836600> <ID:<1047832.1259114400535.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection59.session63.consumer65)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114400535&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    ####<Nov 24, 2009 8:16:37 PM CST> <> <> <1259115397823> <610200> <ID:<1047832.1259114400432.0>> <> <JMSModule!Queue> <Consumed> <<anonymous>> <MC:CA(/<IP_BOX1>):OAMI(server.jms.connection69.session73.consumer75)> <&lt;?xml version="1.0" encoding="UTF-8"?&gt;
    &lt;mes:WLJMSMessage xmlns:mes="http://www.bea.com/WLS/JMS/Message"&gt;&lt;mes:Header&gt;&lt;mes:JMSTimestamp&gt;1259114400432&lt;/mes:JMSTimestamp&gt;&lt;mes:Properties/&gt;&lt;/mes:Header&gt;&lt;/mes:WLJMSMessage&gt;> <>
    Kindly throw some light on this issue. Also do let me know if you need any more specific details about this.
    Thanks,
    Abhijeet
    Edited by: user5240164 on Nov 25, 2009 11:35 AM
    Edited by: user5240164 on Nov 28, 2009 1:21 PM

    Hi,
    The problem may be conflicting names in your configuration. To ensure proper operation of WL Security, JMS, JTA, and JDBC, make sure that (A) each domain has a unique name, and (B) no two WebLogic servers have the same name (even if in two different domains).
    To ensure a more even distribution of messages, either simply send more than a token amount messages (eg, a hundred or so, rather than just 12), or configure a custom connection factory on the domain that hosts the queue, reduce MessagesMaximum on the connection factory to 1, and then modify each MDB to refer to the custom connection factory. The MessagesMaximum setting controls the number of messages that can be pre-pushed (pipelined) to a single asynchronous consumer.
    For more information see "Best Practices for JMS Beginners and Advanced Users" in the latest versions of the JMS admin guide, and "JMS Performance & Tuning Check List" in the WebLogic Performance and Tuning guide.
    Tom

  • JMS messages stuck in queue in weblogic v923 cluster

    Hi all,
    Enviornment details:
    In our pre-production weblogic v923 cluster enviornment with Oracle 10g database, there are 10 server boxes with 2 managed nodes running on each server box in linux enviornment.
    There are 3 JMS queues and 1 error queue per managed node.
    All the queues are durable and the persitence store is a database table. There is a single database table per single managed node.
    High loads of JMS messages from client applications coming on each of the 3 JMS queue are processed by the cluster on daily basis.
    The JMS messages that failed to be processed the very first time due to the application logic exceptions are put on error queue since the retry is set to zero on the non-error queue.
    The application exceptions are logged to a database table for futher reference.
    The falied messages from the error queue are read by spring based MDP and resent to the application for reprocessing.
    If no application exceptions, the message will be persisted in a relational database; in the case of failures, MDP code puts the failed message back on to the error queue.
    The auto_ack is true on the JMS message.
    It is observed about less than 1% of the messages fail the original processing and are in error queue on daily basis.
    99.9% of the time, the reprocessing of the messages from the error queue is a success.
    Currently due to some obvious reasons, the system administrator stops a managed node when the disk is full and start a different managed node on the same server box. This approach will be stopped in the very near future so that all nodes on all servers are running at any point of time by making few enviornment changes.
    Problem:
    1a) Occasionally, it is observed that 1 - 4 JMS messages are stuck in the error queue. There are no signs of reprocessing as there are no application exceptions or the corresponing insert into the database. The JMS persistence store table still has the JMS message.
    1b) It is observed that over time, the same JMS messages that were originally stuck on server 1's managed node A are no longer there but are found in a different node (say node B) on a different server box.
    As far as I understand the JMS, a message could be in a Pending state if MDP (in my case) does not automatically send ACKNOWLEGMENT back due to an issue in the Spring Defaultlisternercontainer before calling MDP's onMessage(). I am not sure as what happens to that status over time).
    It is also observed that the stuck messages content is not much different than the other messages that are processed fine.
    Any pointers/input is highly appreciated.
    Thanks in advance for your valuable input and time.

    Off the top of my head, I can only think of two reasons why a message might move from node to node:
    (A) An application is dequeueing them and enquening them elsewhere.
    (B) The application is using distributed queues, and the distributed queue has been configured to enable "queue forwarding". The forwarding feature automatically moves messages from distributed queue members that have no consumers to members that do have consumers. Queue forwarding is sometimes enabled as a work-around to better enable MDP support of WL distributed destinations, unlike WebLogic MDBs, MDPs have no container logic to ensure that all members of a distributed destination are serviced by a consumer under all circumstances...
    Regards,
    Tom

  • JMS messaging not working with LCDS and Fiorano

    Hi there,
    Been struggling at this all day with no luck. I have a finished Flex application which uses JMS messaging, and it has worked just fine on my Tomcat server while using ActiveMQ. As soon as I switched to using the JMS provider Fiorano however, my application can no longer use JMS resources. It fails whenever the application tries to subscribe or publish to a JMS topic. I made all the appropriate JMS related changes to messaging-config.xml.
    In the tomcat log, I turned on LCDS debugging and saw this error whenever a publisher or subscriber was trying to start:
    "JMS invocation caught exception: SECURITY_EXCEPTION :: Security exception occurred while trying to perform operation :: CreateSubscriber failed,creation of Non-durable Subscriber NOT allowed."
    I am passing my JMS security credentials via messaging-config.xml AND even tried doing it via the Flex application (setRemoteCredentials(..)). I know they are correct because I have a working Java application with the exact same credentials and other JMS settings working just fine. It seems only the Flex application fails using the same JMS credentials/settings.
    Is there some other file that needs modification other than messaging-config.xml to get a new JMS provider to work? Any idea what may be going on?
    Thanks!

    A large number of messages, or messages large in size, basically total size of all messages can hang things up.  Back up your messages with a GPStore app.  Erase them.  Lower your message character size.  IF it still continues, its the recipients phone.  Both of you should power down, remove SIM, reinsert, power up.

  • How to send a JMS message to a remote Queue?

    Hi,
    I know how to create a JMS message and send it to an MDB that listens to a topic in the same container in which the JMS is created.
    In other words, if I have the following MDB:
    @MessageDriven(mappedName = "jms/MyQueue", ...)
    public class MyMDB implements MessageListener {
    Elsewhere in my JEE app I can create a Queue like this:
    @Resource(mappedName = "jms/MyQueue")
    Queue queue;
    and use it to send a message to the MDB.
    But How can I send a message to an MDB that's deployed in another app server on another machine in the network? Both of the app servers are Glassfish.
    Thanks in advance.
    Edited by: EJP on 9/08/2011 21:49: fixed your meaningless title

    Hi,
    The first thing I would like to suggest is, we never/can't send message directly to MDB. We always send/receive message(s) to/from the destination. In case of MDB, the application server register the MDB as message listener against particular destination, and invoked the onMessage() method when message arrives on particular destination.
    If I am not wrong, what you want to achieve is asynchronous communication between two applications deployed in two different machine. In your case, you want your one application works as message producer and other act as an message consumer, and both are deployed in different machine.
    In this situations, you only need to configure the JMS administration object, connection factories and destinations, on one Application server and configure other application server to use those configuration using JMS resource adapter. you can well achieve this by configuring the JMS Resource Adapter. you need to check the Glassfish documentation.
    If you don't want to break the JMS specification, always communicate with Messaging Provider through Resource Adapter.
    I hope this helps.

  • Wy douse the bridge override time to live for individual jms-messages?

    Hi, we have a problem with time to live for individual jms-messages.
              We have a JMS-bridge (ASYNC) between two wls, one application publish a jms masseage on a jms queue with the QueueSender. When the message i sent we set the time to live for the jms-message.
              The bridge then transport the jms message from one wls to the an other. When the message i received on the subscriper side the message time to live is no longer set to the value we specified, the value is now overrided with the default time to live value set on the source ConnectionFactor.
              How do prevent the override of the time to live value.
              Regards
              /Johan

    Hi,
              If the target destination is WL 9.0 or higher you can configure the bridge to preserve message properties -- the MBean attribute name is "PreserveMsgProperty".
              Alternatively, if source and target destination are WL 9.0 or higher, you can configure WebLogic store-and-forward instead of a bridge.
              Finally, if the expiration time is always the same relative to the current time at the point when the bridge forwards the message, you can administratively configure the target destination with a "TimeToLiveOverride" (via the destination configuration itself - not the bridge configuration).
              Tom

  • Weblogic Message Bridge Producing Duplicate JMS Messages

    We have a message bridge that we use to integrate with TIBCO. The message bridge is deployed on a WL cluster. We see duplicate JMS messages produced by the bridge when it is deployed on the cluster. We don't see this behavior when only one ManagedServer in the cluster is active,.
    TIBCO version: 4.4.3 V5
    WLS: 10.3.3 with patch for bug BUG8732539 (BQC6)
    java -version
    java version "1.6.0_17"
    Java(TM) SE Runtime Environment (build 1.6.0_17-b04)
    Oracle JRockit(R) (build R28.0.0-679-130297-1.6.0_17-20100312-2121-linux-x86_64, compiled mode)
    We are also seeing a lot of exceptions related to
    <May 27, 2011 4:11:57 PM PDT> <Warning> <Connector> <BEA-190032> << eis/jms/WLSConnectionFactoryJNDIXA > ResourceAllocationException thrown by resource adapter on call to ManagedConnectionFactory.createManagedConnection(): "javax.resource.ResourceException: Failed to start the connection ">
    However the bridge is active. We are monitoring the message-out count on TIBCO and we observed that we see duplicates whenever there a message is re-delivered. We opened a case with Oracle support and they suggested patch 10258751 which didn't help. The next suggestion was a patch for "Bug 11852771 - [WLS10.3.2]MISSING AND DUPLICATE IN JMS QUEUE MESSAGE MONITORING" but I don't think it will help since our JMS consumers are getting duplicate messages and this is not just a UI issue.
    Here is the message behavior when we send a single message:
    Timelines
    11:34:17 --> Message sent to TIBCO EMS queue
    11:34:17 --> WL MS3 throws an javax.transaction.SystemException: start() failed on resource 'eis/jms/WLSConnectionFactoryJNDIXA': XAER_RMFAIL : Resource manager is unavailable exception
    11:34:17 --> WL MS1 says it got the message and committed the transaction
    11:34:17 --> Message is visible in the JMS queue in the admin console
    11:34:17 --> TIBCO EMS has still not received an ACK from WL for the message
    11:34:31 --> TIBCO EMS resends the same JMS message to WL
    11:34:31 --> WL MS2 says it got the message and committed the transaction
    11:34:31 --> WL MS1 throws an javax.transaction.SystemException: start() failed on resource 'eis/jms/WLSConnectionFactoryJNDIXA': XAER_RMFAIL : Resource manager is unavailable exception
    11:34:31 --> Message is visible in the JMS queue in the admin console (At this point there are two messages in the JMS queue)
    11:34:31 --> TIBCO EMS has still not received an ACK from WL for the message
    11:34:54 --> TIBCO EMS resends the same JMS message to WL
    11:34:31 --> WL MS4 says it got the message and committed the transaction
    11:34:31 --> WL MS2 throws an javax.transaction.SystemException: start() failed on resource 'eis/jms/WLSConnectionFactoryJNDIXA': XAER_RMFAIL : Resource manager is unavailable exception
    11:34:31 --> Message is visible in the JMS queue in the admin console (At this point there are three messages in the JMS queue)
    11:34:31 --> TIBCO EMS receives an ACK from WL for the message
    MS04
    ####<May 27, 2011 11:34:54 AM PDT> <Debug> <MessagingBridgeRuntime> <> <MS04> <[ACTIVE] ExecuteThread: '109' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <BEA1-6A59E8FE76C4FC4CA149> <> <1306521294611> <BEA-000000> <Bridge: MessageBridge1 (processMessages()) received message:
    JMS Message Class: TextMessage
    JMSMessageID: ID:MS01.4B044DDFEE1F1:25354AD
    JMSCorrelationID: null
    JMSDeliveryMode: PERSISTENT
    JMSDestination: Queue[SourceQueue1]
    JMSExpiration: 0
    JMSPriority: 4
    JMSRedelivered: true
    JMSReplyTo: null
    JMSTimestamp: 1306521256905 (Fri May 27 11:34:16 PDT 2011)
    JMSType: null
    Transaction Id: BEA1-6A59E8FE76C4FC4CA149
    <?xml version="1.0" encoding="UTF-8"?>
    <commands ...
    >
    ####<May 27, 2011 11:34:54 AM PDT> <Debug> <MessagingBridgeRuntime> <MS04> <MS04> <[ACTIVE] ExecuteThread: '109' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <BEA1-6A59E8FE76C4FC4CA149> <> <1306521294611> <BEA-000000> <Bridge: MessageBridge1 (processMessages()) successfully sent message:
    JMS Message Class: TextMessage
    Old JMS MessageID: ID:MS01.4B044DDFEE1F1:25354AD
    New JMS MessageID: ID:<193654.1306521294611.0>
    <?xml version="1.0" encoding="UTF-8"?>
    <commands ...
    >
    MS03
    ####<May 27, 2011 11:34:17 AM PDT> <Debug> <MessagingBridgeRuntime> <MS03> <MS03> <[ACTIVE] ExecuteThread: '30' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1306521257342> <BEA-000000> <Bridge MessageBridge1 Successfully got connection to the target destination>
    ####<May 27, 2011 11:34:17 AM PDT> <Debug> <MessagingBridgeRuntime> <MS03> <MS03> <[ACTIVE] ExecuteThread: '30' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1306521257343> <BEA-000000> <Bridge MessageBridge1: both source and target adapters support XA = true>
    ####<May 27, 2011 11:34:17 AM PDT> <Debug> <MessagingBridgeRuntime> <MS03> <MS03> <[ACTIVE] ExecuteThread: '30' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1306521257343> <BEA-000000> <Bridge MessageBridge1 supportsMDBTX = false supportsXA = true async = true>
    ####<May 27, 2011 11:34:17 AM PDT> <Debug> <MessagingBridgeRuntime> <MS03> <MS03> <[ACTIVE] ExecuteThread: '30' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1306521257343> <BEA-000000> <Bridge MessageBridge1 WorkMode = Exactly-once>
    ####<May 27, 2011 11:34:17 AM PDT> <Debug> <MessagingBridgeRuntimeVerbose> <MS03> <MS03> <[ACTIVE] ExecuteThread: '30' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1306521257343> <BEA-000000> <Bridge MessageBridge1 Entering processMessages() ------ >
    ####<May 27, 2011 11:34:17 AM PDT> <Error> <MessagingBridge> <MS03> <MS03> <[ACTIVE] ExecuteThread: '30' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <BEA1-3AA29116A4CA622834EA> <> <1306521257343> <BEA-200015> <An error occurred in bridge "MessageBridge1" during the transfer of messages (java.lang.Exception: javax.resource.ResourceException: Failed to setup the Resource Adapter Connection for enlistment in the transaction, Pool = 'eis/jms/WLSConnectionFactoryJNDIXA', javax.transaction.SystemException: start() failed on resource 'eis/jms/WLSConnectionFactoryJNDIXA': XAER_RMFAIL : Resource manager is unavailable
    javax.transaction.xa.XAException: Internal error: XAResource 'eis/jms/WLSConnectionFactoryJNDIXA' is unavailable
    at weblogic.transaction.internal.XAResourceDescriptor.checkResource(XAResourceDescriptor.java:948)
    at weblogic.transaction.internal.XAResourceDescriptor.startResourceUse(XAResourceDescriptor.java:634)
    at weblogic.transaction.internal.XAServerResourceInfo.start(XAServerResourceInfo.java:1227)
    at weblogic.transaction.internal.XAServerResourceInfo.xaStart(XAServerResourceInfo.java:1161)
    at weblogic.transaction.internal.XAServerResourceInfo.enlist(XAServerResourceInfo.java:282)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistResource(ServerTransactionImpl.java:507)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistResource(ServerTransactionImpl.java:434)
    at weblogic.connector.transaction.outbound.XATxConnectionHandler.enListResource(XATxConnectionHandler.java:117)
    at weblogic.connector.outbound.ConnectionWrapper.invoke(ConnectionWrapper.java:218)
    at $Proxy62.receive(Unknown Source)
    at weblogic.jms.bridge.internal.MessagingBridge.processMessages(MessagingBridge.java:1431)
    at weblogic.jms.bridge.internal.MessagingBridge.beginForwarding(MessagingBridge.java:1006)
    at weblogic.jms.bridge.internal.MessagingBridge.run(MessagingBridge.java:1083)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    at weblogic.connector.transaction.outbound.XATxConnectionHandler.enListResource(XATxConnectionHandler.java:200)
    at weblogic.connector.outbound.ConnectionWrapper.invoke(ConnectionWrapper.java:218)
    at $Proxy62.receive(Unknown Source)
    at weblogic.jms.bridge.internal.MessagingBridge.processMessages(MessagingBridge.java:1431)
    at $Proxy62.receive(Unknown Source)
    at weblogic.jms.bridge.internal.MessagingBridge.processMessages(MessagingBridge.java:1431)
    at weblogic.jms.bridge.internal.MessagingBridge.beginForwarding(MessagingBridge.java:1006)
    at weblogic.jms.bridge.internal.MessagingBridge.run(MessagingBridge.java:1083)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: javax.transaction.SystemException: start() failed on resource 'eis/jms/WLSConnectionFactoryJNDIXA': XAER_RMFAIL : Resource manager is unavailable
    javax.transaction.xa.XAException: Internal error: XAResource 'eis/jms/WLSConnectionFactoryJNDIXA' is unavailable
    at weblogic.transaction.internal.XAResourceDescriptor.checkResource(XAResourceDescriptor.java:948)
    at weblogic.transaction.internal.XAResourceDescriptor.startResourceUse(XAResourceDescriptor.java:634)
    at weblogic.transaction.internal.XAServerResourceInfo.start(XAServerResourceInfo.java:1227)
    at weblogic.transaction.internal.XAServerResourceInfo.xaStart(XAServerResourceInfo.java:1161)
    at weblogic.transaction.internal.XAServerResourceInfo.enlist(XAServerResourceInfo.java:282)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistResource(ServerTransactionImpl.java:507)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistResource(ServerTransactionImpl.java:434)
    at weblogic.connector.transaction.outbound.XATxConnectionHandler.enListResource(XATxConnectionHandler.java:117)
    at weblogic.connector.outbound.ConnectionWrapper.invoke(ConnectionWrapper.java:218)
    at $Proxy62.receive(Unknown Source)
    at weblogic.jms.bridge.internal.MessagingBridge.processMessages(MessagingBridge.java:1431)
    at weblogic.jms.bridge.internal.MessagingBridge.beginForwarding(MessagingBridge.java:1006)
    at weblogic.jms.bridge.internal.MessagingBridge.run(MessagingBridge.java:1083)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    at weblogic.transaction.internal.XAServerResourceInfo.xaStart(XAServerResourceInfo.java:1185)
    at weblogic.transaction.internal.XAServerResourceInfo.enlist(XAServerResourceInfo.java:282)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistResource(ServerTransactionImpl.java:507)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistResource(ServerTransactionImpl.java:434)
    at weblogic.connector.transaction.outbound.XATxConnectionHandler.enListResource(XATxConnectionHandler.java:117)
    ... 8 more
    ).>
    ####<May 27, 2011 11:34:17 AM PDT> <Warning> <MessagingBridge> <MS03> <MS03> <[ACTIVE] ExecuteThread: '30' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1306521257344> <BEA-200026> <Bridge "MessageBridge1" encountered some problems in one of its adapters or underlying systems. It stopped transferring messages and will try to reconnect to the adapters shortly. (The exception caught was java.lang.Exception: MessagingBridgeException: Messaging bridge operation failed
    .)>
    MS02
    ####<May 27, 2011 11:34:31 AM PDT> <Debug> <MessagingBridgeRuntime> <MS02> <MS02> <[ACTIVE] ExecuteThread: '5' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <BEA1-679AF074F381152F047C> <> <1306521271386> <BEA-000000> <Bridge: MessageBridge1 (processMessages()) received message:
    JMS Message Class: TextMessage
    JMSMessageID: ID:MS01.4B044DDFEE1F1:25354AD
    JMSCorrelationID: null
    JMSDeliveryMode: PERSISTENT
    JMSDestination: Queue[SourceQueue1]
    JMSExpiration: 0
    JMSPriority: 4
    JMSRedelivered: true
    JMSReplyTo: null
    JMSTimestamp: 1306521256905 (Fri May 27 11:34:16 PDT 2011)
    JMSType: null
    Transaction Id: BEA1-679AF074F381152F047C
    <?xml version="1.0" encoding="UTF-8"?>
    <commands ...
    >
    ####<May 27, 2011 11:34:31 AM PDT> <Debug> <MessagingBridgeRuntime> <MS02> <MS02> <[ACTIVE] ExecuteThread: '5' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <BEA1-679AF074F381152F047C> <> <1306521271392> <BEA-000000> <Bridge: MessageBridge1 (processMessages()) successfully sent message:
    JMS Message Class: TextMessage
    Old JMS MessageID: ID:MS01.4B044DDFEE1F1:25354AD
    New JMS MessageID: ID:<196075.1306521271386.0>
    <?xml version="1.0" encoding="UTF-8"?>
    <commands ...
    >
    ####<May 27, 2011 11:34:54 AM PDT> <Error> <MessagingBridge> <MS02> <MS02> <[ACTIVE] ExecuteThread: '5' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1306521294610> <BEA-200015> <An error occurred in bridge "MessageBridge1" during the transfer of messages (java.lang.Exception: weblogic.transaction.RollbackException: start() failed on resource 'eis/jms/WLSConnectionFactoryJNDIXA': XAER_RMERR : A resource manager error has occured in the transaction branch
    javax.transaction.xa.XAException
    at weblogic.connector.security.layer.AdapterLayer.setTransactionTimeout(AdapterLayer.java:495)
    at weblogic.connector.transaction.outbound.XAWrapper.setTransactionTimeout(XAWrapper.java:457)
    at weblogic.connector.transaction.outbound.RecoveryOnlyXAWrapper.setTransactionTimeout(RecoveryOnlyXAWrapper.java:34)
    at weblogic.transaction.internal.XAResourceDescriptor.setXAResourceTransactionTimeoutIfAppropriate(XAResourceDescriptor.java:1422)
    at weblogic.transaction.internal.XAServerResourceInfo.start(XAServerResourceInfo.java:1223)
    at weblogic.transaction.internal.XAServerResourceInfo.xaStart(XAServerResourceInfo.java:1161)
    at weblogic.transaction.internal.XAServerResourceInfo.enlist(XAServerResourceInfo.java:282)
    at weblogic.transaction.internal.XAServerResourceInfo.enlistIfStatic(XAServerResourceInfo.java:181)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistStaticallyEnlistedResources(ServerTransactionImpl.java:1565)
    at weblogic.transaction.internal.ServerTransactionManagerImpl.dispatchRequest(ServerTransactionManagerImpl.java:551)
    at weblogic.messaging.dispatcher.DispatcherServerRef.handleRequest(DispatcherServerRef.java:132)
    at weblogic.messaging.dispatcher.DispatcherServerRef.access$000(DispatcherServerRef.java:34)
    at weblogic.messaging.dispatcher.DispatcherServerRef$2.run(DispatcherServerRef.java:111)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: java.lang.NullPointerException
    at weblogic.connector.security.layer.AdapterLayer.setTransactionTimeout(AdapterLayer.java:485)
    ... 14 more
    at weblogic.transaction.internal.TransactionImpl.throwRollbackException(TransactionImpl.java:1871)
    at weblogic.transaction.internal.ServerTransactionImpl.internalCommit(ServerTransactionImpl.java:330)
    at weblogic.transaction.internal.ServerTransactionImpl.commit(ServerTransactionImpl.java:225)
    at weblogic.transaction.internal.TransactionManagerImpl.commit(TransactionManagerImpl.java:293)
    at weblogic.jms.bridge.internal.MessagingBridge.processMessages(MessagingBridge.java:1534)
    at weblogic.jms.bridge.internal.MessagingBridge.beginForwarding(MessagingBridge.java:1006)
    at weblogic.jms.bridge.internal.MessagingBridge.run(MessagingBridge.java:1083)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: javax.transaction.SystemException: start() failed on resource 'eis/jms/WLSConnectionFactoryJNDIXA': XAER_RMERR : A resource manager error has occured in the transaction branch
    javax.transaction.xa.XAException
    at weblogic.connector.security.layer.AdapterLayer.setTransactionTimeout(AdapterLayer.java:495)
    at weblogic.connector.transaction.outbound.XAWrapper.setTransactionTimeout(XAWrapper.java:457)
    at weblogic.connector.transaction.outbound.RecoveryOnlyXAWrapper.setTransactionTimeout(RecoveryOnlyXAWrapper.java:34)
    at weblogic.transaction.internal.XAResourceDescriptor.setXAResourceTransactionTimeoutIfAppropriate(XAResourceDescriptor.java:1422)
    at weblogic.transaction.internal.XAServerResourceInfo.start(XAServerResourceInfo.java:1223)
    at weblogic.transaction.internal.XAServerResourceInfo.xaStart(XAServerResourceInfo.java:1161)
    at weblogic.transaction.internal.XAServerResourceInfo.enlist(XAServerResourceInfo.java:282)
    at weblogic.transaction.internal.XAServerResourceInfo.enlistIfStatic(XAServerResourceInfo.java:181)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistStaticallyEnlistedResources(ServerTransactionImpl.java:1565)
    at weblogic.transaction.internal.ServerTransactionManagerImpl.dispatchRequest(ServerTransactionManagerImpl.java:551)
    at weblogic.messaging.dispatcher.DispatcherServerRef.handleRequest(DispatcherServerRef.java:132)
    at weblogic.messaging.dispatcher.DispatcherServerRef.access$000(DispatcherServerRef.java:34)
    at weblogic.messaging.dispatcher.DispatcherServerRef$2.run(DispatcherServerRef.java:111)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: java.lang.NullPointerException
    at weblogic.connector.security.layer.AdapterLayer.setTransactionTimeout(AdapterLayer.java:485)
    ... 14 more
    at weblogic.transaction.internal.XAServerResourceInfo.xaStart(XAServerResourceInfo.java:1185)
    at weblogic.transaction.internal.XAServerResourceInfo.enlist(XAServerResourceInfo.java:282)
    at weblogic.transaction.internal.XAServerResourceInfo.enlistIfStatic(XAServerResourceInfo.java:181)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistStaticallyEnlistedResources(ServerTransactionImpl.java:1565)
    at weblogic.transaction.internal.ServerTransactionManagerImpl.dispatchRequest(ServerTransactionManagerImpl.java:551)
    at weblogic.messaging.dispatcher.DispatcherServerRef.handleRequest(DispatcherServerRef.java:132)
    at weblogic.messaging.dispatcher.DispatcherServerRef.access$000(DispatcherServerRef.java:34)
    at weblogic.messaging.dispatcher.DispatcherServerRef$2.run(DispatcherServerRef.java:111)
    ... 2 more
    ).>
    ####<May 27, 2011 11:34:54 AM PDT> <Warning> <MessagingBridge> <MS02> <MS02> <[ACTIVE] ExecuteThread: '5' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1306521294610> <BEA-200026> <Bridge "MessageBridge1" encountered some problems in one of its adapters or underlying systems. It stopped transferring messages and will try to reconnect to the adapters shortly. (The exception caught was java.lang.Exception: MessagingBridgeException: Messaging bridge operation failed
    MS01
    ####<May 27, 2011 11:34:17 AM PDT> <Debug> <MessagingBridgeRuntime> <MS01> <MS01> <[ACTIVE] ExecuteThread: '36' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <BEA1-72BC818FE2BB8C2655C6> <> <1306521257536> <BEA-000000> <Bridge: MessageBridge1 (processMessages()) received message:
    JMS Message Class: TextMessage
    JMSMessageID: ID:MS01.4B044DDFEE1F1:25354AD
    JMSCorrelationID: null
    JMSDeliveryMode: PERSISTENT
    JMSDestination: Queue[SourceQueue1]
    JMSExpiration: 0
    JMSPriority: 4
    JMSRedelivered: false
    JMSReplyTo: null
    JMSTimestamp: 1306521256905 (Fri May 27 11:34:16 PDT 2011)
    JMSType: null
    Transaction Id: BEA1-72BC818FE2BB8C2655C6
    <?xml version="1.0" encoding="UTF-8"?>
    <commands ...
    >
    ####<May 27, 2011 11:34:17 AM PDT> <Debug> <MessagingBridgeRuntime> <MS01> <MS01> <[ACTIVE] ExecuteThread: '36' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <BEA1-72BC818FE2BB8C2655C6> <> <1306521257542> <BEA-000000> <Bridge: MessageBridge1 (processMessages()) successfully sent message:
    JMS Message Class: TextMessage
    Old JMS MessageID: ID:MS01.4B044DDFEE1F1:25354AD
    New JMS MessageID: ID:<195581.1306521257536.0>
    <?xml version="1.0" encoding="UTF-8"?>
    <commands ...
    >
    ####<May 27, 2011 11:34:31 AM PDT> <Error> <MessagingBridge> <MS01> <MS01> <[ACTIVE] ExecuteThread: '36' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1306521271384> <BEA-200015> <An error occurred in bridge "MessageBridge1" during the transfer of messages (java.lang.Exception: weblogic.transaction.RollbackException: start() failed on resource 'eis/jms/WLSConnectionFactoryJNDIXA': XAER_RMERR : A resource manager error has occured in the transaction branch
    javax.transaction.xa.XAException
    at weblogic.connector.security.layer.AdapterLayer.setTransactionTimeout(AdapterLayer.java:495)
    at weblogic.connector.transaction.outbound.XAWrapper.setTransactionTimeout(XAWrapper.java:457)
    at weblogic.connector.transaction.outbound.RecoveryOnlyXAWrapper.setTransactionTimeout(RecoveryOnlyXAWrapper.java:34)
    at weblogic.transaction.internal.XAResourceDescriptor.setXAResourceTransactionTimeoutIfAppropriate(XAResourceDescriptor.java:1422)
    at weblogic.transaction.internal.XAServerResourceInfo.start(XAServerResourceInfo.java:1223)
    at weblogic.transaction.internal.XAServerResourceInfo.xaStart(XAServerResourceInfo.java:1161)
    at weblogic.transaction.internal.XAServerResourceInfo.enlist(XAServerResourceInfo.java:282)
    at weblogic.transaction.internal.XAServerResourceInfo.enlistIfStatic(XAServerResourceInfo.java:181)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistStaticallyEnlistedResources(ServerTransactionImpl.java:1565)
    at weblogic.transaction.internal.ServerTransactionManagerImpl.dispatchRequest(ServerTransactionManagerImpl.java:551)
    at weblogic.messaging.dispatcher.DispatcherServerRef.handleRequest(DispatcherServerRef.java:132)
    at weblogic.messaging.dispatcher.DispatcherServerRef.access$000(DispatcherServerRef.java:34)
    at weblogic.messaging.dispatcher.DispatcherServerRef$2.run(DispatcherServerRef.java:111)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: java.lang.NullPointerException
    at weblogic.connector.security.layer.AdapterLayer.setTransactionTimeout(AdapterLayer.java:485)
    ... 14 more
    at weblogic.transaction.internal.TransactionImpl.throwRollbackException(TransactionImpl.java:1871)
    at weblogic.transaction.internal.ServerTransactionImpl.internalCommit(ServerTransactionImpl.java:330)
    at weblogic.transaction.internal.ServerTransactionImpl.commit(ServerTransactionImpl.java:224)
    at weblogic.transaction.internal.TransactionManagerImpl.commit(TransactionManagerImpl.java:293)
    at weblogic.jms.bridge.internal.MessagingBridge.processMessages(MessagingBridge.java:1534)
    at weblogic.jms.bridge.internal.MessagingBridge.beginForwarding(MessagingBridge.java:1006)
    at weblogic.jms.bridge.internal.MessagingBridge.run(MessagingBridge.java:1083)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: javax.transaction.SystemException: start() failed on resource 'eis/jms/WLSConnectionFactoryJNDIXA': XAER_RMERR : A resource manager error has occured in the transaction branch
    javax.transaction.xa.XAException
    at weblogic.connector.security.layer.AdapterLayer.setTransactionTimeout(AdapterLayer.java:495)
    at weblogic.connector.transaction.outbound.XAWrapper.setTransactionTimeout(XAWrapper.java:457)
    at weblogic.connector.transaction.outbound.RecoveryOnlyXAWrapper.setTransactionTimeout(RecoveryOnlyXAWrapper.java:34)
    at weblogic.transaction.internal.XAResourceDescriptor.setXAResourceTransactionTimeoutIfAppropriate(XAResourceDescriptor.java:1422)
    at weblogic.transaction.internal.XAServerResourceInfo.start(XAServerResourceInfo.java:1223)
    at weblogic.transaction.internal.XAServerResourceInfo.xaStart(XAServerResourceInfo.java:1161)
    at weblogic.transaction.internal.XAServerResourceInfo.enlist(XAServerResourceInfo.java:282)
    at weblogic.transaction.internal.XAServerResourceInfo.enlistIfStatic(XAServerResourceInfo.java:181)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistStaticallyEnlistedResources(ServerTransactionImpl.java:1565)
    at weblogic.transaction.internal.ServerTransactionManagerImpl.dispatchRequest(ServerTransactionManagerImpl.java:551)
    at weblogic.messaging.dispatcher.DispatcherServerRef.handleRequest(DispatcherServerRef.java:132)
    at weblogic.messaging.dispatcher.DispatcherServerRef.access$000(DispatcherServerRef.java:34)
    at weblogic.messaging.dispatcher.DispatcherServerRef$2.run(DispatcherServerRef.java:111)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: java.lang.NullPointerException
    at weblogic.connector.security.layer.AdapterLayer.setTransactionTimeout(AdapterLayer.java:485)
    ... 14 more
    at weblogic.transaction.internal.XAServerResourceInfo.xaStart(XAServerResourceInfo.java:1185)
    at weblogic.transaction.internal.XAServerResourceInfo.enlist(XAServerResourceInfo.java:282)
    at weblogic.transaction.internal.XAServerResourceInfo.enlistIfStatic(XAServerResourceInfo.java:181)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistStaticallyEnlistedResources(ServerTransactionImpl.java:1565)
    at weblogic.transaction.internal.ServerTransactionManagerImpl.dispatchRequest(ServerTransactionManagerImpl.java:551)
    at weblogic.messaging.dispatcher.DispatcherServerRef.handleRequest(DispatcherServerRef.java:132)
    at weblogic.messaging.dispatcher.DispatcherServerRef.access$000(DispatcherServerRef.java:34)
    at weblogic.messaging.dispatcher.DispatcherServerRef$2.run(DispatcherServerRef.java:111)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    ... 1 more
    ).>
    ####<May 27, 2011 11:34:31 AM PDT> <Warning> <MessagingBridge> <MS01> <MS01> <[ACTIVE] ExecuteThread: '36' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1306521271384> <BEA-200026> <Bridge "MessageBridge1" encountered some problems in one of its adapters or underlying systems. It stopped transferring messages and will try to reconnect to the adapters shortly. (The exception caught was java.lang.Exception: MessagingBridgeException: Messaging bridge operation failed
    .)>

    @Tom, thanks for your hints and sorry for my delayed response. Here are my answers to your queries…
    -- Does messaging work, without any exceptions, when only one bridge is active?
    It works fine when only one node of the cluster is active. -- I'm not familiar with Tibco monitoring, but I suspect that the "message-out count on TIBCO" stat doesn't always imply that there's a duplicate message. It could mean that an initial message delivery attempt failed, it's transaction rolled back, and the message was redelivered. Redelivery after a failure is normal - the original delivered message, if one actually made it onto a WebLogic queue, should be discarded by WebLogic when its failed transaction eventually rolls back (before its ever handed to a consumer application).
    You are absolutely right. The mismatch in count was due to redelivery attempts. We could see that as soon as we turned on trace in TIBCO-- The posted stack traces look like they may be JVM stdout/stderr scrapes, which are often automatically truncated, for example, see the "... 8 more" listed at the bottom of one of the stack traces below. There might be more information in the full stack trace for the "Resource manager is unavailable" exception. Full traces are logged in each WebLogic Server's log files.
    I tried redirecting the output and even set "stdout Stack Trace Depth:" to -1 but I am not albe to see the complete trace.-- The setTransactionTimeout NullPointerException error message looks like it is collateral damage from the original reported "Resource manager is unavailable" exception that's thrown earlier during the enlistResource() step. If you are truly getting duplicates, then I think this is a clue that the bridge is somehow (stupidly) trying to proceed with forwarding the message despite the fact that there's no current transaction on the thread...

    I have a case open with Oracle support and we have extensive debugging turned on. Here is what the engineer came back with. There is an issue with XA transactions in JCA adapter when it talks to third party providers like TIBCO. Since the resource names are not unique across the cluster, a XA transaction is started on multiple nodes in the cluster for the same message. All transactions abort but the message is persisted and TIBCO redelivers the message since the connection is severed when the transaction aborts. We were able to reproduce this scenario at will with our setup and Oracle was able to reproduce the issue too. 
-- Can you check the state of the message on the WebLogic Q? The fact that a message is shown on the WL console doesn't necessarily mean that the state of the message is visible (it could be waiting for the transaction to commit - something that apparently never happens). On the console: Services -> Messaging -> JMS Modules -> [module name] -> [destination name].

    Our consumer was getting duplicate messages. This confirms that the console was not giving us incorrect information. The console showed that 2/3/4 messages were in "current" state when we expected only one message.
-- Make sure that the bridge's Tibco destination is a Tibco queue not a Tibco topic (it's happened).

    Yeah we made sure it was a Queue.
-- Can you post your bridge and destination stanzas from your config.xml? 

    Will try to do this shortly but have to strip out lot of information.
-- I vaguely recall that there was a problem with untyped connection factories in Tibco at one point (not sure). You might want to try changing the Tibco configuration to spin-up "XA Queue Connection Factory" instead of just an "XA Connection Factory" (plus modify the bridge configuration accordingly).

    We tried this but it didn't eliminate this issue. One thing we did notice however was that the number of rollbacks were greatly reduced.

    Here is the workaround that Oracle is suggesting: Create pinned destinations and assign it to a distributed queue. This will keep the transactions local and hence eliminate the duplicate transactions and rollback. We tried it and it eliminated the dups issue. However I discovered another bug during my testing. Our cluster messaging mode is "Unicast" and message forwarding from zero consumer queues to queues with consumers fails. We have four/five nodes in the cluster and two consumer threads. I observed that the zero consumer queues always forward to one queue in the cluster that has consumers. The forwarding stalls when I bring down the node that has consumers. Again, we were able to reproduce this issue at will and Oracle has acknowledged that it is a bug. They've reported that Unicast fails without any warning whereas Multicast fails with a warning in the log. We have observed this message forwarding stalling even with UDQs.
    I have another case open for an issue where our message bridges that transfer messages from TIBCO to WLS stalls after sometime. The status is shown as active but it is not doing anything. The server instance shows stuck threads trying to roll back a message. TIBCO logs indicate that it is receiving a request to rollback a transaction but it is not finding the transaction to rollback. The only way to recover from this condition is to restart the cluster. I am fairly confident that he root case for this issue is again the XA transaction issue. I changed our UDQ to pinned destination in one environment and we are no longer seeing dups or bridge stalling there. Hopefully Oracle can resolve the message forwarding issue.Thanks again….

  • How to send a JMS message to a server ....

    Hi
    I want to know how to send a jms message to a Queue and that is in a different server...
    How to send A message using a application client to a Message queue That is in another Machine(Server is in another machine )
    env.put(Context.INITIAL_CONTEXT_FACTORY,"com.sun.jndi.cosnaming.CNCtxFactory");
    env.put(Context.PROVIDER_URL, "iiop://127.0.0.1:3700/");
    InitialContext initialContext = new InitialContext(env);
    connectionFactory = (ConnectionFactory) initialContext.lookup("jms/ConnectionFactory");
    queue = (Queue) initialContext.lookup("jms/Queue");
    get a NameNotFoundException
    Anyone have an Idea
    thanks
    Ishkmi
    Message was edited by:
    ishkmi

    ok..try this..insert the ip address of the server where ur app server is
    running . i understand ur client and server is running on diff machines.
    ip address 127.0.0.1 is for local host. it tries to look for the server in
    same system as the client.
    substitue ip address of server in below line instead of 127.0..0.1
    env.put(Context.PROVIDER_URL, "iiop://127.0.0.1:3700/");
    best of luck ..lemme know..

Maybe you are looking for

  • How can I delete the extension .html in the web browser if I do not have Business Catalyst?

    I have been working on my site for quite some time but just realized that if I type in www.website.com/page it will not work unless I type in www.website.com/page.html.  This will be really detrimental for my client.  Is there a way to allow customer

  • External Display for iBook

    I'm thinking about purchasing a 19" lcd monitor for use with my 12" iBook. I need something that makes photo editing easier. I'm looking at either a Viewsonic VA1930WM or a Samsung 906BW. Does anyone any experience with either of these monitors or an

  • Goods receipts

    hello all In MIGO transaction, I can make goods receipt agianst PO ,reservation....etc. I want to change the text of that reference document , i mean according to user requirement and system is not allow to chenge the des. in spro - setting for enjoy

  • Why can't I send any more than 5 TCP messages per second on an NT system?

    Help! I am trying to send a message (approximately 50 bytes long) every 22 ms (45.4 Hz) to the only other machine on our network (the server). I am using the following function: Status = ClientTCPWrite(Conversation_Handle, Pointer_to_the_data, Size_o

  • Render HTML TEXT

    I have a problem... in my Movie clip i use a share font, i import in a Dymanic Text a TXT file as html text. If I use character embedding hmtl tag doesn't work, if i don't embed character html tag works correctly. I need use character embedding becau