Friday 15 February 2013

java - OpenJPA @FetchGroup -


I am using @FatchGroup to load class statistics, in each category parents / children Can be the category or not. I only need 2 level data, which means Category - & gt; Sub Level 1 - & gt; Sub Level 2 * I do not want to make a full effort of the category, because this will affect performance. I will be @FetchGroup (name = FetchGroupConstants.CATEGORY_CHILD_LEVEL_2, attribute = {@FetchAttribute (name = "children", recursionDepth = 2)}) Adds in the unit square. After this I also used the following group to get the data

@FetchGroup (name = FetchGroupConstants.CATEGORY_BASIC, attributes = {@FetchAttribute (name = "ordering"), @FetchAttribute (name Then I found the whole tree "ResursionDepth = -1" similar results if I set recursionDepth = 1, then I also get the full tree. What is the problem I am using "FetchPlan"? Thank you.

Let me use the entire tree in the server cache for now. Any suggestions

No comments:

Post a Comment