Re: Profiling Tapestry
"Howard M. Lewis Ship" <[email protected]> Thu, 19 Dec 2002 18:20:45 -0500
| Newsgroups | gmane.comp.java.tapestry.contrib |
|---|---|
| Message-ID | <005201c2a7b5$42bd0c00$3dc41e42@howardczkz2sl3> |
Hm.
That might be an area to look into. Since all Tapestry output is run
through IMarkupWriter .... we don't absolutely have to base it on a
PrintWriter. Still, if we read templates as bytes, we'd have to do a lot of
our own conversion back to char just to parse the damn thing. I guess the
templates start as binary, convert to char, and convert back to binary on
the way to the browser.
How is this different than JSP? Most of the JSP implementations put the
template into strings and have endless out.print("....") statements.
----- Original Message -----
From: "Luis Neves" <[email protected]>
To: "Tapestry Contrib" <tapestry-contrib-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org>
Sent: Tuesday, February 19, 2002 3:52 PM
Subject: Re: [Tapestry-contrib] Profiling Tapestry
>
> I stopped measuring "Elapsed Time" and started measuring "CPU Time"
> and the results are making more sense, also I pick a very simple page
> (it's only a static page with a Tapestry BasePage associated) in order
> do reduce the noise ,and because I've always been curious as to why
> Tapestry works so hard with pages that are mostly static, I mean, no
> matter how complex a page is, Tapestry always seems to do the same
> effort.
>
> It looks like what's keeping Tapestry down is the use of
> PrintWriter.
> See:
>
> <http://pwp.netcabo.pt/lneves/tapestry_Run2.html>
>
> I remember sometime ago reading a paper from Sun about servlet
> performance where they conclude (among other things):
>
> - Converting chars to bytes is *very slow*
> - Always use OutputStream, never PrintWriter
> - Store bytes, not characters
>
> Ok ... I know ... This is probably preaching to the choir :-)
> The paper is online:
> <http://java.sun.com/javaone/javaone2001/pdfs/551.pdf>
>
> The problem is of course that PrintWriter may very well be the only
> thing available that Tapestry can use ... and in that case we are
> screewed :-)
>
>
> Best regards,
> Luis Neves
>
>
>
> ----- Original Message -----
> From: "Luis Neves" <[email protected]>
> To: "Tapestry Contrib" <tapestry-contrib-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org>
> Sent: Tuesday, February 19, 2002 3:38 PM
> Subject: [Tapestry-contrib] Profiling Tapestry
>
>
> >
> > I'm trying out the JProbe profiler suite using a Tapestry Application
> > ( using a "net.sf.tapestry" filter) and it seems that Tapestry spends
> > most of the time sleeping :-) , see here:
> >
> > <http://pwp.netcabo.pt/lneves/tapestry_Run.html>
> >
> > The big offender seems to be the JanitorThread used by the Tapestry
> > Pool.
> > Does this make sense? I have no idea of how to interpret the
> > results... it seems that using a profiler is somekind of a black art.
> >
> > Best regards,
> > Luis Neves
> >
> >
> > -------------------------------------------------------
> > This SF.NET email is sponsored by: Geek Gift Procrastinating?
> > Get the perfect geek gift now! Before the Holidays pass you by.
> > T H I N K G E E K . C O M http://www.thinkgeek.com/sf/
> > _______________________________________________
> > Tapestry-contrib mailing list
> > Tapestry-contrib-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
> > https://lists.sourceforge.net/lists/listinfo/tapestry-contrib
>
>
> -------------------------------------------------------
> This SF.NET email is sponsored by: Geek Gift Procrastinating?
> Get the perfect geek gift now! Before the Holidays pass you by.
> T H I N K G E E K . C O M http://www.thinkgeek.com/sf/
> _______________________________________________
> Tapestry-contrib mailing list
> Tapestry-contrib-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
> https://lists.sourceforge.net/lists/listinfo/tapestry-contrib
>
-------------------------------------------------------
This SF.NET email is sponsored by: Geek Gift Procrastinating?
Get the perfect geek gift now! Before the Holidays pass you by.
T H I N K G E E K . C O M http://www.thinkgeek.com/sf/