| Javadogs, Here's what I'm proposing, in summary. 1. Add a property to FetchPlan: get/setMaxFetchDepth. This property limits the depth of the fetched instance graph counting from the root of the instances. The roots are defined for queries as the results of the query. The roots of retrieve and detachCopy are the parameter instances. The default is 1, meaning fetch one level of objects reachable from the roots. A value of 0 has no meaning, because if a relationship field is in the fetch group, it will be fetched. 2. Add a property to FetchPlan: get/setDetachRoots. The roots for DetachAllOnCommit are all the instances in the DetachRoots on FetchPlan. The default is all instances in the cache. Or it could be all instances retrieved by queries, explicitly made persistent, or explicitly retrieved. 3. In order to avoid confusion, remove fetch-depth attribute for the field element and replace it with recursion-depth attribute. This has two effects: it requires users to change their metadata and think about what the fetch-depth was used for; and it better reflects the purpose of the attribute to limit recursion. The meaning of recursion-depth is the maximum number of links to follow from the target instance of this field in case the same class is encountered again. 4. In case of multiple definitions of the same field recursion-depth, the largest number for the same field will be used. That is, if the same field is declared in multiple fetch groups, a simple MAX of all the values is used. I'll write up a number of examples and send them tomorrow. Comments? Craig On Jan 13, 2006, at 3:10 PM, Craig L Russell wrote: Javadogs, Craig Russell Architect, Sun Java Enterprise System http://java.sun.com/products/jdo 408 276-5638 mailto:[EMAIL PROTECTED] P.S. A good JDO? O, Gasp! |
smime.p7s
Description: S/MIME cryptographic signature
