You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Jozsa Kristof <dy...@kami.vein.hu> on 2002/02/11 20:16:16 UTC

Benchmarking aggregations

Hi,

  I've donated an hour, and did some manual benchmarking of my Cocoon2
project, which is in early state, but is already slow, so I thought I look
after.. I've made the benchmarks with the unix tools 'time' and 'wget',
wgetting a page a fewhundred times, and calculated the average results, each
tests repeated a few times. It's not accurate, but sure better then nothing.

  My sitemap contains several aggregations, uses custom Generators pulling
xml data from EJBs and such. It uses a 'self-invented' block-layouts-pages
theory, so every page is aggregated TWICE: the page contains layouts, which
are aggregated, and layouts contains block, which are aggregated again. I've
removed the internal-only flag from all my pipelines, so I could measure
each separately.

  The results are strange. It roughly shows, that for the FIRST aggregation
(putting together a layout from blocks), I get almost the same results, than
the 'blocks' rendering time summed up, with almost no addon aggregation
time. (Eg. two blocks with 0.025s each aggregation can be done in 0.055s).

  But, at the second aggregation, the time needed for aggregation of layouts
(and nothing else, I've removed all transformators and funky stuff for the
test) multiplies, and goes up to the sky: three layouts with rendering times
0.055s, 0.160s and 0.045s get aggregated and displayed in provoking ~1.25
seconds(!!). I've repeated the tests many times, and checked the sitemap,
but it just does the very same as before, where aggregation time was almost
unnoticeable.

  Anyone can explain this symptom? It was months ago when I read all the
Cocoon concept docs, but can't remember any warning that I shouldn't
aggregate content twice in my sitemap, or similar. Do I get it right that
the second level aggregation causes the slowdown, or can it be anything else
as well? Anyone with some better Cocoon2 background knowledge can explain
the situation please?


Christopher

ps. all these happens on Cocoon 2.0.1, running in JBoss3 snapshot under
Jetty. The cocoon.xconf file was stripped, I've removed some not needed
parts like xmldb, hsql and such, but it's not really tuned or tweaked yet.
-- 
.Digital.Yearning.for.Networked.Assassination.and.Xenocide

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>


Solved: Re: Benchmarking aggregations

Posted by Jozsa Kristof <dy...@kami.vein.hu>.
On Mon, Feb 11, 2002 at 04:44:13PM -0500, Vadim Gritsenko wrote:
> > From: Jozsa Kristof [mailto:dynax@kami.vein.hu]
> > 
> > On Mon, Feb 11, 2002 at 02:35:19PM -0500, Vadim Gritsenko wrote:
> > > Suggestion:
> > > Save results of these three blocks (0.055s, 0.160s and 0.045s) into
> a
> > > files and change second aggregation to aggregate these files, then
> > > benchmark again. Thus, you will get time of the second aggregation
> > > without other pipelines.
> > >
> > > I wonder what results you will get with this :)
> > >
> > > Vadim
> > >
> > 
> > Let me see if I get you right: I've saved the results of the first
> > aggregation (3 files), into static xml files, and wrote a sitemap
> rule,
> > which just aggregates these three files. The avarage
> > read+aggregation+serialization time of this is 11 milliseconds.
> ('Dodge
> > this' =)
> > 
> > I've migrated to Apache JMeter meanwhile, and verified my rough wget
> > results. They're so-so correct (a few ms higher sometimes, a few ms
> lower
> > otherwise, but generally they were ok).
> > 
> > So what do you think?
> 
> Can you post your sitemap snippet - with both aggregations? May be after
> watching at it some ideas appear. Right now I don't have any, except may
> be usual "tune your pools" advice.
> 
> PS I have several level aggregations, and it works well for me. 
> 
> Vadim

Shortly: it wasn't about aggregation, nor my new sitemap structure. It all
happened, cos I switched from C2.0 to Cocoon 2.0.1 meanwhile, and it has
really expansive logging, switched on by default.. I've turned it off, and
average page processing time dropped from 1200ms (even 2200 on some pages!)
to 200-300.

Sorry, my fault - seems I've missed the release note about that :)

Christopher
-- 
.Digital.Yearning.for.Networked.Assassination.and.Xenocide

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>


RE: Benchmarking aggregations

Posted by Vadim Gritsenko <va...@verizon.net>.
> From: Jozsa Kristof [mailto:dynax@kami.vein.hu]
> 
> On Mon, Feb 11, 2002 at 02:35:19PM -0500, Vadim Gritsenko wrote:
> > Suggestion:
> > Save results of these three blocks (0.055s, 0.160s and 0.045s) into
a
> > files and change second aggregation to aggregate these files, then
> > benchmark again. Thus, you will get time of the second aggregation
> > without other pipelines.
> >
> > I wonder what results you will get with this :)
> >
> > Vadim
> >
> 
> Let me see if I get you right: I've saved the results of the first
> aggregation (3 files), into static xml files, and wrote a sitemap
rule,
> which just aggregates these three files. The avarage
> read+aggregation+serialization time of this is 11 milliseconds.
('Dodge
> this' =)
> 
> I've migrated to Apache JMeter meanwhile, and verified my rough wget
> results. They're so-so correct (a few ms higher sometimes, a few ms
lower
> otherwise, but generally they were ok).
> 
> So what do you think?

Can you post your sitemap snippet - with both aggregations? May be after
watching at it some ideas appear. Right now I don't have any, except may
be usual "tune your pools" advice.

PS I have several level aggregations, and it works well for me. 

Vadim

> 
> Christopher
> --
> .Digital.Yearning.for.Networked.Assassination.and.Xenocide


---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>


Re: Benchmarking aggregations

Posted by Jozsa Kristof <dy...@kami.vein.hu>.
On Mon, Feb 11, 2002 at 02:35:19PM -0500, Vadim Gritsenko wrote:
> Suggestion:
> Save results of these three blocks (0.055s, 0.160s and 0.045s) into a
> files and change second aggregation to aggregate these files, then
> benchmark again. Thus, you will get time of the second aggregation
> without other pipelines.
> 
> I wonder what results you will get with this :)
> 
> Vadim
> 

Let me see if I get you right: I've saved the results of the first
aggregation (3 files), into static xml files, and wrote a sitemap rule,
which just aggregates these three files. The avarage
read+aggregation+serialization time of this is 11 milliseconds. ('Dodge
this' =)

I've migrated to Apache JMeter meanwhile, and verified my rough wget
results. They're so-so correct (a few ms higher sometimes, a few ms lower
otherwise, but generally they were ok).

So what do you think?

Christopher
-- 
.Digital.Yearning.for.Networked.Assassination.and.Xenocide

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>


RE: Benchmarking aggregations

Posted by Vadim Gritsenko <va...@verizon.net>.
> From: Jozsa Kristof [mailto:dynax@kami.vein.hu]
> 
> Hi,
> 
>   I've donated an hour, and did some manual benchmarking of my Cocoon2
> project, which is in early state, but is already slow, so I thought I
look
> after.. I've made the benchmarks with the unix tools 'time' and
'wget',
> wgetting a page a fewhundred times, and calculated the average
results, each
> tests repeated a few times. It's not accurate, but sure better then
nothing.
> 
>   My sitemap contains several aggregations, uses custom Generators
pulling
> xml data from EJBs and such. It uses a 'self-invented'
block-layouts-pages
> theory, so every page is aggregated TWICE: the page contains layouts,
which
> are aggregated, and layouts contains block, which are aggregated
again. I've
> removed the internal-only flag from all my pipelines, so I could
measure
> each separately.
> 
>   The results are strange. It roughly shows, that for the FIRST
aggregation
> (putting together a layout from blocks), I get almost the same
results, than
> the 'blocks' rendering time summed up, with almost no addon
aggregation
> time. (Eg. two blocks with 0.025s each aggregation can be done in
0.055s).
> 
>   But, at the second aggregation, the time needed for aggregation of
layouts
> (and nothing else, I've removed all transformators and funky stuff for
the
> test) multiplies, and goes up to the sky: three layouts with rendering
times
> 0.055s, 0.160s and 0.045s get aggregated and displayed in provoking
~1.25
> seconds(!!). I've repeated the tests many times, and checked the
sitemap,
> but it just does the very same as before, where aggregation time was
almost
> unnoticeable.

Suggestion:
Save results of these three blocks (0.055s, 0.160s and 0.045s) into a
files and change second aggregation to aggregate these files, then
benchmark again. Thus, you will get time of the second aggregation
without other pipelines.

I wonder what results you will get with this :)

Vadim

 
>   Anyone can explain this symptom? It was months ago when I read all
the
> Cocoon concept docs, but can't remember any warning that I shouldn't
> aggregate content twice in my sitemap, or similar. Do I get it right
that
> the second level aggregation causes the slowdown, or can it be
anything else
> as well? Anyone with some better Cocoon2 background knowledge can
explain
> the situation please?
> 
> 
> Christopher
> 
> ps. all these happens on Cocoon 2.0.1, running in JBoss3 snapshot
under
> Jetty. The cocoon.xconf file was stripped, I've removed some not
needed
> parts like xmldb, hsql and such, but it's not really tuned or tweaked
yet.
> --
> .Digital.Yearning.for.Networked.Assassination.and.Xenocide



---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>