Uploaded image for project: 'Jackrabbit Content Repository'
  1. Jackrabbit Content Repository
  2. JCR-2545

removing a versionable Node and its baseversion within a XA Transaction gives XAException when this Node was created outside a transaction

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.5.5, 1.5.6, 1.5.7, 1.6, 1.6.1
    • None
    • transactions, versioning
    • None

    Description

      When I remove a Node and its versions within a XA transaction I get a XAException, when this Node was created outside a transaction.

      First add a node not using any transaction. After that doing the following within a XATransaction:

      1. remove the added Node
      2. remove the baseVersion of the Node
      3. commit -> XAException

      After debugging I noticed the cause of the XAException is a ReferentialIntegrityException. It seems within the transaction the removal of the Node is not added to the changelog. Therefor a ReferentialIntegrityException is thrown because JackRabbit thinks the baseVersion is still used by the Node. Which it shoudn't since it is already removed.

      The strange thing is, when the Node was also created within a transaction, all goes well.

      I have created a TestCase with the failing and the passing test.

      Attachments

        1. repository.xml
          2 kB
          quipere
        2. RemoveVersionsWithinTransactionTestCase.java
          6 kB
          quipere

        Activity

          People

            Unassigned Unassigned
            quipere quipere
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: