Is is possible to update a child object directly(never calling the
parent) and still reliably keep the 'owned one to many' relationship?
I have been doing this on one of my apps and then noticed that the
children will sometimes become orphaned from the parent. I'm trying to
track down the problem but it occurred to me that this may be messing
up the index or something strange like that.

Does this make sense or should i elaborate more?

the structure is similar to:

public class UserObj {
         @PrimaryKey
         @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
         private Long id;
        @Persistent
        private List<VehicleObj> Vehicles;
        public Long getId() {
                return id;
        }
        public void setId(Long id) {
                this.id = id;
        }
        public List<VehicleObj> getVehicles() {
                return Vehicles;
        }
        public void setVehicles(List<VehicleObj> vehicles) {
                Vehicles = vehicles;
        }

}


....
later on I update one of the VehicleObj's based on a search without
ever instantiating the parent UserObj and every so often i loose a
vehicle that should be attached to the UserObj. It's still in the
datastore just orphaned.

This may not be the problem but i thought it was a good place to start
tracking it down.

--

You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=.


Reply via email to