JDO
  1. JDO
  2. JDO-412

Expectation of jdoPostLoad() invocation does not take into account the possibility of persistent-nontransactional state

    Details

      Description

      Some tests assume that jdoPostLoad() will be called, but do not take into account the possibilty that persistent-nontransactional is a valid state, and that jdoPostLoad() is not invoked for those instances. The solution should be to force instances to be transitioned to persistent-clean after commit by setting RetainValues=false.

      This affects the following tests:

      org.apache.jdo.tck.api.instancecallbacks.CallingJdoPostload.test
      org.apache.jdo.tck.api.instancecallbacks.ModificationOfNontransactionalNonpersistentFields.test

      The solution is to invoke "setRetainValues(false)" after obtaining the transaction in both the test cases. E.g.:

      Transaction t = pm.currentTransaction();
      t.setRetainValues(false);

        Activity

        Marc Prud'hommeaux created issue -
        Michael Bouschen made changes -
        Field Original Value New Value
        Assignee Michael Bouschen [ mbo ]
        Michael Bouschen made changes -
        Fix Version/s JDO 2 maintenance release 1 [ 12310923 ]
        Description
        Some tests assume that jdoPostLoad() will be called, but do not take into account the possibilty that persistent-nontransactional is a valid state, and that jdoPostLoad() is not invoked for those instances. The solution should be to force instances to be transitioned to persistent-clean after commit by setting RetainValues=false.

        This affects the following tests:

         org.apache.jdo.tck.api.instancecallbacks.CallingJdoPostload.test
         org.apache.jdo.tck.api.instancecallbacks.ModificationOfNontransactionalNonpersistentFields.test

        The solution is to invoke "setRetainValues(false)" after obtaining the transaction in both the test cases. E.g.:

                Transaction t = pm.currentTransaction();
                t.setRetainValues(false);
        Some tests assume that jdoPostLoad() will be called, but do not take into account the possibilty that persistent-nontransactional is a valid state, and that jdoPostLoad() is not invoked for those instances. The solution should be to force instances to be transitioned to persistent-clean after commit by setting RetainValues=false.

        This affects the following tests:

         org.apache.jdo.tck.api.instancecallbacks.CallingJdoPostload.test
         org.apache.jdo.tck.api.instancecallbacks.ModificationOfNontransactionalNonpersistentFields.test

        The solution is to invoke "setRetainValues(false)" after obtaining the transaction in both the test cases. E.g.:

                Transaction t = pm.currentTransaction();
                t.setRetainValues(false);
        Hide
        Michael Bouschen added a comment -

        Checked in the proposed fix into the trunk and the 2.0.1 branch (see revision 452606).

        Show
        Michael Bouschen added a comment - Checked in the proposed fix into the trunk and the 2.0.1 branch (see revision 452606).
        Michael Bouschen made changes -
        Fix Version/s JDO 2.0 TCK challenge fixes [ 12312093 ]
        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
        34d 13h 3m 1 Michael Bouschen 03/Oct/06 20:57
        Resolved Resolved Closed Closed
        1349d 15h 11m 1 Andy Jefferson 14/Jun/10 12:08

          People

          • Assignee:
            Michael Bouschen
            Reporter:
            Marc Prud'hommeaux
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development