6 Replies Latest reply on Jun 19, 2003 12:44 AM by Adrian Brock

    WARN LocalTxConnectionManager message

    janoss Newbie

      I am using JBoss 3.0.6, JBossMQ, MDBs and SessionBeans.

      When the MDB calls a SessionBean which then calls the findByPrimaryKey method of an Entity bean while handling an incoming JMS message I get the following warning:

      WARN [LocalTxConnectionManager$LocalConnectionEventListener] prepare called on a local tx. You are not getting the semantics you expect!

      When the MDB does not make a call to an Entity Finder method via the Session bean fascade bean there's no warning.

        • 1. Re: WARN LocalTxConnectionManager message
          Adrian Brock Master

          Your db has does not support XA.


          • 2. Re: WARN LocalTxConnectionManager message
            janoss Newbie

            Is this good or bad. If it only a warning and does not affect my entities, how can I turn off all of the JBoss warning messages?

            • 3. Re: WARN LocalTxConnectionManager message
              janoss Newbie

              What is the reslolution for this? If it does not affect the entity, how can I diable these numerous warning messages?

              • 4. Re: WARN LocalTxConnectionManager message
                Jon Barnett Master

                The warnings indicate that things might not work as you anticipate. It is not strictly critical, but might affect the data committed. However, this is too complex a matter for the container to decide. You need to analyse your transactions and determine if there is a possibility that this is harmful.

                You can filter out all warnings in your container by setting your threshold to ERROR in your log4j.xml configuration for the instance you are running. For example, if you are running the default instance, the file would be server/default/conf/log4j.xml.

                You can also adjust it for different categories which might be more appropriate. See the documentation and the examples in log4j.xml.

                • 5. Re: WARN LocalTxConnectionManager message
                  janoss Newbie

                  Eureka. Since nothing is ever documented, I used the old hammer technique and beat on the jboss.xml file until I corrected the problem. Hiding the warn messages is unacceptable since I want things to work correctly.

                  What did I do? Despite being unable to set the following using JBuilder 9, I manually added the following lines to my jboss.xml file inside the 'Message Bean' declaration. I should write a book.


                  Now when my message bean gets a message via onMessage off of the topic. It does not complain when it performs actions on the Entity beans which are using mysql. God I hate this stuff. Give me C, Perl, and bash anyday.

                  • 6. Re: WARN LocalTxConnectionManager message
                    Adrian Brock Master

                    That does not fix underlying the problem.
                    You now have two transactions instead of one.

                    One could rollback, one could commit.
                    All you have done is stop jboss detecting the problem.

                    The underlying problem is that your db doesn't
                    have support for two phase commit.