Uploaded image for project: 'JBoss Transaction Manager'
  1. JBoss Transaction Manager
  2. JBTM-329

When BridgeParticipantAT receives prepare, participant should associate current thread with corresponding JTA transaction

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 4.7.0
    • None
    • XTS
    • None

    Description

      When participant receives prepare from coordinator, it calls prepare on jta transaction. SubordinateAtomicAction.doPrepare then calls beforeCompletion() method. Hibernate registers Synchronization object which is called in beforeCompletion() method. In that synchronization object, when hibernate cannot find transaction on current thread, it flushes all entites into database, which is bad.
      When Hibernate cannot find transaction on thread, it logs WARN [AbstractEntityManagerImpl] Transaction not available on beforeCompletionPhase: assuming valid

      Fix is easy, BridgeParticipantAT should associate current thread with the corresponding JTA transaction. And finally it should suspend that JTA transaction.

      Attachments

        Issue Links

          Activity

            People

              rhn-engineering-jhallida Jonathan Halliday
              kadlecp Pavel Kadlec (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: