Re: Fetch Optimization Advice
Re: Fetch Optimization Advice
- Subject: Re: Fetch Optimization Advice
- From: Mike Schrag <email@hidden>
- Date: Wed, 8 Jul 2009 16:24:41 -0400
speaking without knowledge of any specifics of your app, it's
generally number of roundtrips that is the big performance killer
rather than the number of columns that come back, unless you have an
especially large number of columns that have especially large data ...
if it's #2, and this is just reporting, i would recommend making some
custom views that only pull back what you need and make new eo's that
sit on top of those views. my first thought is that you're probably
not prefetching effectively, but that's a completely naive comment --
just what screws most people for performance. Turn on sql debug and
do you see a ton of faults of to-one's and to-many's? if so, those
are prime candidates for ERXBatchFetchUtilities to prefetch them in
bulk. if the fetches you see are appropriately faulting, only THEN
would i start to look at other things like column counts and raw rows.
ms
On Jul 8, 2009, at 4:19 PM, Mr. Frank Cobia wrote:
I have created a WebObjects command line app (uses ERXMainRunner)
that generates a report for each user (40,000+) on my system and it
is running too slow. I have come up with two ways to optimize it and
I was wondering which you thought is better.
The report uses a table (TableA) that has a lot of fields, most of
which are not relevant to the report. It also has a Text field which
could be rather large.
One option is to create TableAReport that points to the same
database table, but only include the few (small) fields that I need
for the report. I know the downside to this is that WebObjects can
get confused when there are two entities pointing to the same data,
but this command line app is only run once a day, it is read only
and (hopefully) only runs for a few minutes.
The other is to go to raw row fetches, but I lose some of the nice
EOF stuff like traversing relationships. (TableA has two
relationship I use).
Any Advice?
Thanks,
Frank
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden