JDO
  1. JDO
  2. JDO-513

StateTransitionsReturnedObjects expects persistent-clean in optimistic transaction

    Details

      Description

      StateTransitionsReturnedObjects fails with:

      junit.framework.AssertionFailedError:
      Assertions A5.9-1 through A5.5.8 (serialization, detachment, attachment) failed:
      StateTransitionsReturnedObjects: optimistic transaction; current state detached-clean
      makePersistent returned instance in invalid state hollow; expected state persistent-clean

      It seems that in optimistic transaction the object state should be non transactional.

        Activity

        Ilan Kirsh created issue -
        Hide
        Craig L Russell added a comment -

        The specification doesn't explicitly cover this case, although I agree that the state transition should be as you indicate. The state transition table 2 near 5.8 has an entry for makePersistent but doesn't split out datastore transaction versus optimistic transaction.

        For now, we can mark this test case as UNSPECIFIED and document and fix it in maintenance (both the specification and the test case).

        Show
        Craig L Russell added a comment - The specification doesn't explicitly cover this case, although I agree that the state transition should be as you indicate. The state transition table 2 near 5.8 has an entry for makePersistent but doesn't split out datastore transaction versus optimistic transaction. For now, we can mark this test case as UNSPECIFIED and document and fix it in maintenance (both the specification and the test case).
        Hide
        Craig L Russell added a comment -

        The specification dated 2007-09-28 has been updated to split the row in the state transitions table so that the returned state in datastore transaction is persistent-clean but in optimistic transaction is persistent-nontransactional.

        The test case needs to be updated now.

        Show
        Craig L Russell added a comment - The specification dated 2007-09-28 has been updated to split the row in the state transitions table so that the returned state in datastore transaction is persistent-clean but in optimistic transaction is persistent-nontransactional. The test case needs to be updated now.
        Hide
        Craig L Russell added a comment -

        Since the spec was deficient, the branch for test case challenges should be updated to skip this test, and the trunk should be updated to check for persistent-clean for datastore transactions and persistent-nontransactional for optimistic.

        Show
        Craig L Russell added a comment - Since the spec was deficient, the branch for test case challenges should be updated to skip this test, and the trunk should be updated to check for persistent-clean for datastore transactions and persistent-nontransactional for optimistic.
        Craig L Russell made changes -
        Field Original Value New Value
        Assignee Michelle Caisse [ mcaisse ]
        Hide
        Craig L Russell added a comment -

        The spec was updated to reflect that with an optimistic transaction, makePersistent transitions detached instances to persistent-nontransactional:

        This change now makes JPOX fail the StateTransitionsReturnedObjects test.

        Show
        Craig L Russell added a comment - The spec was updated to reflect that with an optimistic transaction, makePersistent transitions detached instances to persistent-nontransactional: This change now makes JPOX fail the StateTransitionsReturnedObjects test.
        Craig L Russell made changes -
        Assignee Michelle Caisse [ mcaisse ] Andy Jefferson [ andy ]
        Hide
        Andy Jefferson added a comment -

        JPOX SVN has been changed to match the moved goalposts of the TCK, now passes

        Show
        Andy Jefferson added a comment - JPOX SVN has been changed to match the moved goalposts of the TCK, now passes
        Andy Jefferson made changes -
        Fix Version/s JDO 2 maintenance release 1 [ 12310923 ]
        Resolution Fixed [ 1 ]
        Status Open [ 1 ] Resolved [ 5 ]
        Andy Jefferson made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open Resolved Resolved
        121d 21h 22m 1 Andy Jefferson 09/Dec/07 09:52
        Resolved Resolved Closed Closed
        918d 1h 17m 1 Andy Jefferson 14/Jun/10 12:10

          People

          • Assignee:
            Andy Jefferson
            Reporter:
            Ilan Kirsh
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development