[appengine-java] Re: Persistence problem of an entity with two List of the same type

2009-09-22 Thread Jason (Google)
Hi Édouard. This is a known issue -- at the moment, there is no good way to model trees in the datastore where all nodes are of the same type. As others have suggested, you can use more than one class with the same properties to do this, which should work for shallow trees. You may also be able to

[appengine-java] Re: Persistence problem of an entity with two List of the same type

2009-09-21 Thread elDoudou
Thank you Maciej for your answer. But I think that my problem is not related to any empty field. The problem of storage arises as soon as you define twice a persistent field which is a list of the same type, as I explained earlier. The only work-around I found is to duplicate the listed

[appengine-java] Re: Persistence problem of an entity with two List of the same type

2009-09-21 Thread Nicolas Melendez
Hi, i think your problem is here: @Persistent private ListB list1 = new ArrayListB(); you use a List, but you assing an ArrayList. That because the datastore makes different structures for different types of collection. To fix that, your code should be: @Persistent private ArrayList B list1