cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robin Green" <gree...@hotmail.com>
Subject Fwd: Re: performance issues
Date Wed, 13 Sep 2000 19:33:51 GMT
>From: "Jens Lorenz" <jens.lorenz@interface-business.de>
>To: <greenrd@hotmail.com>
>Subject: Re: performance issues
>Date: Wed, 13 Sep 2000 17:44:02 +0200
>
>----- Original Message -----
>From: Robin Green <greenrd@hotmail.com>
>To: <cocoon-users@xml.apache.org>
>Sent: Saturday, September 09, 2000 1:53 AM
>Subject: Re: performance issues
>
>
>Hi Robin,
>
> > >Well. I wonder, if it could be implemented in the xspexpr(Object o,
> > >Document
> > >d)
> > >method of XSPPage.java ... Just a test like
> > >if (o instanceof Node)
> > >   if ( ((Node)o).getOwnerDocument() != d)
> > >     // clone the tree via XSPUtil
> > >   else
> > >     // appendChild and so on
> > >
> > >
> > >... but I've no overview of the Cocoon structure to see if this might
>work
> > >...
> > >
> >
> >
> > Great idea! I see no reason why that shouldn't work. Here is the exact
>patch
> > - I'll apply it as soon as poss.
> >
> > --- src/org/apache/cocoon/processor/xsp/XSPPage.bak     Thu Apr  6
>10:16:10
> > 2000
> > +++ src/org/apache/cocoon/processor/xsp/XSPPage.java    Fri Sep  8
>23:47:10
> > 2000
> >
> > @@ -141,7 +141,12 @@
> >
> >      // Already a node? Use it verbatim
> >      if (v instanceof Node) {
> > -      return XSPUtil.cloneNode((Node) v, factory);
> > +      if (((Node) v).getOwnerDocument () == factory) {
> > +        return (Node) v;
> > +      }
> > +      else {
> > +        return XSPUtil.cloneNode((Node) v, factory);
> > +      }
> >      }
> >
> >      // Array: recurse over each element
>
>I already said, that I applied the patch ... But I just wanted
>to mention, that this little patch _really_ improves the speed
>of Cocoon ...
>I've now ported big parts of my tag lib to Cocoon2 comptabile
>XObject interface and while the average speed was formerly
>around 200 milliseconds it's now just above
>100 milliseconds ... (and the only thing that changed and that
>I'm aware of is this change in Cocoon)
>
>
>Just wanted to say thanks again ...
>
>
>Regards,
>
>Jens
>
>--
>
>jens.lorenz@interface-business.de
>
>interface:business GmbH                             \\|//
>Tolkewitzer Strasse 49                              (o o)
>01277 Dresden                               ~~~~oOOo~(_)~oOOo~~~~
>Germany
>
>

_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at 
http://profiles.msn.com.


Mime
View raw message