5 Replies Latest reply on Jul 24, 2010 3:17 AM by fered

    JBossTS integration with ActiveMQ and Hibernate

    fered

      Hi;

      I want to integrate JbossTS with ActiveMQ and Hibernate.

      Is there any example to help me?

       

      Thanks.

        • 1. Re: JBossTS integration with ActiveMQ and Hibernate
          mmusgrov
          • 2. Re: JBossTS integration with ActiveMQ and Hibernate
            fered

            NOTE: In spite of the example working, transaction management is not working appropriately when it comes to both Hibernate and JBossCache participating of the same transaction. The reason is because at the time of writing this wiki, Hibernate did not allow to inject a JTA Transaction Manager which is not bound to JNDI. In the example, Hibernate creates a JDBC transaction and JBossCache a JTA transaction which are not linked together. To be able to make a Hibernate and JBossCache participant of the same JTA transaction in a standalone environment, customer code needs to be added to Hibernate to get around the JNDI/JTA coupling.

             

            I think this is an old example. Is there a new one? and just Hibernate+JBoss transactions and no JBoss cache.

            Thank you

            • 3. Re: JBossTS integration with ActiveMQ and Hibernate
              mmusgrov

              fered fered wrote:

               

              NOTE: In spite of the example working, transaction management is not working appropriately when it comes to both Hibernate and JBossCache participating of the same transaction. The reason is because at the time of writing this wiki, Hibernate did not allow to inject a JTA Transaction Manager which is not bound to JNDI. In the example, Hibernate creates a JDBC transaction and JBossCache a JTA transaction which are not linked together. To be able to make a Hibernate and JBossCache participant of the same JTA transaction in a standalone environment, customer code needs to be added to Hibernate to get around the JNDI/JTA coupling.

               

              I think this is an old example. Is there a new one? and just Hibernate+JBoss transactions and no JBoss cache.

              Thank you

               

              I'm not aware of any example. Why don't you bind the transaction manager into JNDI manually. There are articles on developing JNDI applications on the Sun Developer Network - it is actually only a few lines of code.

              • 4. Re: JBossTS integration with ActiveMQ and Hibernate
                mmusgrov

                I believe whitingjr has some examples that cover this scenario - perhaps he will respond.

                • 5. Re: JBossTS integration with ActiveMQ and Hibernate
                  fered

                  I can't understand what's you'r mean.

                  I need distributed transactions between some nodes that use hibernate and activemq.

                   

                  I think JBoss transactions can help me.