On Monday 11 August 2008 15:50:39 you wrote:
> --- moved to [email protected] ---
>
> > I found a disturbing number of objects being created.
> >
> > This numbers show how many objects being created of the top classes:
> >
> > no.sesat.search.query.token.TokenEvaluationEngineImpl$1 192629
> > no.sesat.search.query.token.JepEvaluatorFactory$1 137061
> > no.sesat.search.query.token.RegExpEvaluatorFactory$1 137057
> >
> > Total = 470.706
>
> Errr, this doesn't look like the total to me :-/
> I gather your top numbers are for 1000 requests.
Nope, the numbers are for one single search using the search on the next line.
> > This is the result after one search: "1 2 3 4 5 6 7 8 9 10 11 12 13 14
> > 15"
> >
> > This code's purpose is basically to pass the Site or the FactoryName
> > wrapped in a context object. But instead of creating the context object
> > each time we could store them in the corresponding Site or EvaluatorType.
> > Then they will only be created ones pr. Site/EvaluatorType instance.
>
> Got an example patch?
> I presume you mean something like adding
> "Context getParentSiteContext()"
> to AbstractEvaluatorFactory?
The patch is simply to put the context object inside the Site object.
new SiteContext(){
public Site getSite(){
return cxt.getSite().getParent();
}
}
will just become:
cxt.getSite().getParent().getSiteContext()
> > The total object count after this code changed dropped from 470.706 to
> > 3.959, which is a dramatic drop.
> >
> > for a more sane search "finn sofa" we get this results. (Search repeated)
> >
> > 1. 14.185 to 1.095 (init + search)
> > 2. 17.695 to 1.454
> > 3 26.961 to 1.840
>
> How are you getting decimal places with a fixed search?
I just added the dot to make it easier to to see. So 26.956 is the same as
26956.
> Could you repeat your instrumentation against a warmed up application
> please.
Search number 2 and 3 would be a 'warmed up application'
Håvard
_______________________________________________
Kernel-development mailing list
[email protected]
http://sesat.no/mailman/listinfo/kernel-development