[ http://issues.apache.org/jira/browse/JDO-428?page=all ]

Craig Russell resolved JDO-428.
-------------------------------

    Fix Version/s:     (was: JDO 2 maintenance release 1)
                       (was: JDO 2.0 TCK challenge fixes)
       Resolution: Invalid

The spec describes what happens in the description of makePersistent:

<spec>
For a detached instance, they locate or create a persistent 
instance with the same JDO identity as the detached instance, and merge the 
persistent 
state of the detached instance into the persistent instance. Only the state of 
persistent fields 
is merged.
</spec>

The merge operation cannot result in a hollow instance.

> StateTransitionsReturnedObjects disallows makePersistent() on a 
> detached-clean instance from being hollow
> ---------------------------------------------------------------------------------------------------------
>
>                 Key: JDO-428
>                 URL: http://issues.apache.org/jira/browse/JDO-428
>             Project: JDO
>          Issue Type: Bug
>          Components: tck20
>    Affects Versions: JDO 2 final
>            Reporter: Marc Prud'hommeaux
>         Assigned To: Craig Russell
>            Priority: Minor
>
> Element 10 (0-based) of the "makePersistent" array in 
> org/apache/jdo/tck/lifecycle/StateTransitionsReturnedObjects.java asserts 
> that a detached-clean instance passed to makePersistent() should have the 
> resulting object be in the "persistent-clean" state. However, section 12.6.7 
> of the JDO 2 spec merely says that: "During application of changes of the 
> detached state, if the JDO implementation can determine that there were no 
> changes made during detachment, then the implementation is not required to 
> mark the corresponding instance dirty." Based on this, it should be legal for 
> the object to be in either the hollow state as well as the persistent-clean 
> state.
> The easiest fix, short of changing the test case to allow for multiple 
> states, is to change element 10 from "PERSISTENT_CLEAN" to "IMPOSSIBLE", 
> which will disable the state check altogether.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to