From: Dan G. <da...@st...> - 2009-04-17 17:06:44
|
Hey all, So we're still kicking this idea around, and my brain won't let it rest. We're a little afraid of using the ERXEOAccessUtilities apprach as we really don't want to deal with the object graph being in a funny state. So I've been wondering if we can influence the SQL that is generated when EditingContext.saveChanges() is called. At that point, all the notifications have been sent out and all of that stuff. So when it creates the SQL for deletedObjects, instead of going over each EO one at a time and making "delete from foo where id=bar" could it possibly check to see if there are many EOs of the same class and making a "delete from foo where id in "bar,bar2,bar3" type of dealy-o. I also understand that it needs to visit each EO one at a time to call things like EO.willDelete() on them, I'm wondering if it could do all that, then make the one line of SQL and run it... I'm going as deep as I can with Jad, but I'm way over my head. It seems like a pretty nice optimization to me. Is this possible or am I completely off base? -Dan On 16-Apr-09, at 12:08 PM, Chuck Hill wrote: > > On Apr 16, 2009, at 6:30 AM, Vaughan Van Der Merwe wrote: > >> So if we happen to be using multiple instances as well as a 'Wonder >> cross-instance synching thingy' we could potentially end up in a >> weird state by using this? > > I think a more correct statement would be that the 'Wonder cross- > instance synching thingy' eliminates (or at least greatly reduces) > weird states and using this can bring them back. If you are not using > it, you have to deal with the weird states. Or, as I suspect most > people do, just not worry about them. > > Chuck > > >> >> >> On 15-Apr-09, at 4:34 PM, Chuck Hill wrote: >> >>> >>> On Apr 15, 2009, at 3:07 PM, Mike Schrag wrote: >>> >>>>> Wonder's ERXEOAccessUtilities is what you want. This bypasses all >>>>> the >>>>> EOF validations and delete rules as well, so be aware of that. >>>> and leaves your object graph in an inconsistent state, so you need >>>> to >>>> manually refresh it ... >>> >>> Or just not worry about it. :-) If you are running multiple >>> instances >>> and not using the Wonder cross-instance synching thingy, then this >>> is >>> the same situation as EOF processing the deletes in another >>> instance. >>> >>> >>> Chuck >>> >>> >>> -- >>> Chuck Hill Senior Consultant / VP Development >>> >>> Practical WebObjects - for developers who want to increase their >>> overall knowledge of WebObjects or who are trying to solve specific >>> problems. >>> http://www.global-village.net/products/practical_webobjects >>> >>> >>> >>> >>> >>> >>> >>> ------------------------------------------------------------------------------ >>> Stay on top of everything new and different, both inside and >>> around Java (TM) technology - register by April 22, and save >>> $200 on the JavaOne (SM) conference, June 2-5, 2009, San Francisco. >>> 300 plus technical and hands-on sessions. Register today. >>> Use priority code J9JMT32. http://p.sf.net/sfu/p >>> _______________________________________________ >>> Wonder-disc mailing list >>> Won...@li... >>> https://lists.sourceforge.net/lists/listinfo/wonder-disc >> >> >> > > -- > Chuck Hill Senior Consultant / VP Development > > Practical WebObjects - for developers who want to increase their > overall knowledge of WebObjects or who are trying to solve specific > problems. > http://www.global-village.net/products/practical_webobjects > > > > > > > > ------------------------------------------------------------------------------ > Stay on top of everything new and different, both inside and > around Java (TM) technology - register by April 22, and save > $200 on the JavaOne (SM) conference, June 2-5, 2009, San Francisco. > 300 plus technical and hands-on sessions. Register today. > Use priority code J9JMT32. http://p.sf.net/sfu/p > _______________________________________________ > Wonder-disc mailing list > Won...@li... > https://lists.sourceforge.net/lists/listinfo/wonder-disc |