Re: Avoiding expensive database roundtrips for enterprise objects

2011-05-31 Thread Paul Dunkler
Hi Chuck, sorry for the late answer... Mail just wanted to hide this message from me :) Here are the two traces. Hope this will help [2011-5-31 16:3:57 CAT] WorkerThread14 java.lang.RuntimeException at

Re: Avoiding expensive database roundtrips for enterprise objects

2011-05-31 Thread Chuck Hill
Hi Paul, These are only refaulting the objects, not really invalidating them: at com.xyrality.bk.actions.BKDirectAction.editingContextShouldInvalidateObject(BKDirectAction.java:62) ... at

Re: Avoiding expensive database roundtrips for enterprise objects

2011-05-27 Thread Paul Dunkler
Am 26.05.2011 um 20:28 schrieb Chuck Hill: On May 26, 2011, at 9:03 AM, Paul Dunkler wrote: nice - thank you for the hint. I tried it and i was successfull. But in addition to this fix, it would be nice to know why the default behaviour of the editingContext is to refault all objects on

Re: Avoiding expensive database roundtrips for enterprise objects

2011-05-27 Thread Chuck Hill
Hi Paul, John said: I would presume that this is happening in response to the EOObjectsChangedInStoreNotification. You can implement an EOEditingContext delegate and override editingContextShouldInvalidateObject to see where it is happening and prevent it if you want. I assume that

Avoiding expensive database roundtrips for enterprise objects

2011-05-26 Thread Paul Dunkler
Hey guys, we are currently developing a large webobjects (plus wonder of course) driven backend application. Every time a request comes in, we fetch a big set of data for the customer related to this request. In the following actions we add/edit/delete some of the data originally fetched from

Re: Avoiding expensive database roundtrips for enterprise objects

2011-05-26 Thread Paul Dunkler
nice - thank you for the hint. I tried it and i was successfull. But in addition to this fix, it would be nice to know why the default behaviour of the editingContext is to refault all objects on saveChanges()... maybe anyone can explain? Am 26.05.2011 um 16:40 schrieb John Huss: I would

Re: Avoiding expensive database roundtrips for enterprise objects

2011-05-26 Thread John Huss
I'm far from an expert on this, but I've been digging in this code lately. Look at EOEdtingContext._processObjectStoreChanges. The idea is that since the object was saved, the copies of it in memory in other ECs are out of date and need to be re-read; I believe it is kind of leftover from the

Re: Avoiding expensive database roundtrips for enterprise objects

2011-05-26 Thread Chuck Hill
On May 26, 2011, at 9:03 AM, Paul Dunkler wrote: nice - thank you for the hint. I tried it and i was successfull. But in addition to this fix, it would be nice to know why the default behaviour of the editingContext is to refault all objects on saveChanges()... maybe anyone can explain?

Re: Avoiding expensive database roundtrips for enterprise objects

2011-05-26 Thread Chuck Hill
On May 26, 2011, at 9:10 AM, John Huss wrote: I'm far from an expert on this, but I've been digging in this code lately. Look at EOEdtingContext._processObjectStoreChanges. The idea is that since the object was saved, the copies of it in memory in other ECs are out of date and need to