2 Replies Latest reply on Mar 27, 2007 3:11 AM by - -

    Unable to locate current JTA transaction

    Nitu Lama Newbie

      Hi

      I have jboss jboss-4.0.3SP1 Hibernate 3.

      When attempt to recover the getCurrentSession() , gives the exception


      org.hibernate.HibernateException: Unable to locate current JTA transaction


      Somebody knows the solution? I have found that the problem is in JTA transaction but not like forming my correctly jboss.


      Thank you very much.

        • 1. Re: Unable to locate current JTA transaction
          Fernando Avalos Newbie

          Hi:

          I have exactly the same problem, do you solve it???

          Can any body help me, please???

          Thanks in advance...

          • 2. Re: Unable to locate current JTA transaction
            - - Newbie

            hibernate 3.2.*
            jboss 4.0.5.GA

            im getting the same "unable to locate jta transaction" @TransactionAttributeType.SUPPORTS but not with @TransactionAttributeType.REQUIRED on ejb 3 session bean[slsb].

            i use getCurrentSession().

            i understand hibernate session needs a transaction but what happens when you need to mark something as read only.

            as i understand the only way to mark this is by using @TransactionAttributeType.SUPPORTS.

            is there a way to tell a hibernate session that it should be readonly so that the session doesnot look for a transaction? any work around this if you really need to use @TransactionAttributeType.SUPPORTS?