openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Teresa Kan" <tck...@gmail.com>
Subject FetchGroup and FetchAttribute question
Date Thu, 30 Aug 2007 21:26:28 GMT
If I have a fetchAttribute manager which is included in multiple
FetchGroups. For example,

@FetchGroup(name="ManagerFetchGroup1A",

attributes= {@FetchAttribute(name="manager", recursionDepth=1)} ),

@FetchGroup(name="ManagerFetchGroup1B",

attributes= {@FetchAttribute(name="manager", recursionDepth=-1)} ),

@FetchGroup(name="ManagerFetchGroup2",

attributes= {@FetchAttribute(name="manager", recursionDepth=2)} ),

In my test case, I did the following:

oem.getFetchPlan().resetFetchGroups();  ===> reset to default

oem.clear();

oem.getFetchPlan().addFetchGroups("ManagerFetchGroup1A");

I found out that openjpa will add all 3 FetchGroups back to the fetch plan.
My guess was that the manager was associated with 3 FetchGroups. The
recursionDepth will be set to -1. Is this an expected behavior? I can't find
any statement from the openjpa manual. Please clarifiy!

Thanks,

Teresa

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message