JDO
  1. JDO
  2. JDO-514

StateTransitionsReturnedObjects assumes Non Transactional Write enabled by default

    Details

    • Type: Test Test
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      StateTransitionsReturnedObjects fails with:

      Assertions A5.9-1 through A5.5.8 (serialization, detachment, attachment) failed:
      StateTransitionsReturnedObjects: no transaction; current state persistent-nontransactional-dirty
      serialize outside tx; unexpected exception caught: com.objectdb.jdo._JDOUserException: Attempt to modify an object with no active transaction when NontransactionalWrite is disabled: org.apache.jdo.tck.pc.lifecycle.StateTransitionObj#3
      FailedObject:org.apache.jdo.tck.pc.lifecycle.StateTransitionObj@701a27

      It seems that StateTransitionsReturnedObjects assumes non transactional write enabled by default. Checking if the implementation supports non transactional write is insufficient (when it is not the default setting).

      An explicit:
      pm.currentTransaction().setNontransactionalWrite(true);
      is needed in getPersistentNontransactionalDirtyInstance, before:
      obj.writeField(10000);

        Activity

        Ilan Kirsh created issue -
        Michelle Caisse made changes -
        Field Original Value New Value
        Status Open [ 1 ] Resolved [ 5 ]
        Assignee Michelle Caisse [ mcaisse ]
        Resolution Fixed [ 1 ]
        Fix Version/s JDO 2 maintenance release 1 [ 12310923 ]
        Andy Jefferson made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Michelle Caisse
            Reporter:
            Ilan Kirsh
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development