cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Morrison, John" <John.Morri...@uk.experian.com>
Subject RE: [C2] patch to serializers
Date Tue, 30 Oct 2001 10:22:44 GMT
Joerg,

I looked at the patch you supplied.  In the comments below you say...

"The buffer created in AbstractSerializer was actually never used,
 because all subclasses of AbstractSerializer either didn't use
 super.setOutputStream()"

but if you look, all the files you've patched have...

             super.setOutputStream(out);

Am I missing something?

J.

> -----Original Message-----
> From: Joerg Henne [mailto:j.henne@levigo.de]
> Sent: Monday, 01 October 2001 7:48 pm
> To: cocoon-dev@xml.apache.org
> Subject: [C2] patch to serializers
> 
> 
> Hi,
> 
> the Cocoon2 serializers for text, XML and HTML currently work very
> inefficiently due to the fact that the underlying Xalan 
> serializer writes
> every character in a seperate call to the output stream's 
> write() method. In
> conjunction with a chunked transfer-encoding (the default for 
> HTTP-1.1) this
> leads to a 6-fold increase in the volume of data that hits 
> the wire (it's
> "1\r\n" plus the original character plus "\r\n" - just in 
> case you wondered
> :-).
> 
> The attached patch fixes the problem using a simple 
> BufferedOutputStream. I've
> placed the buffer creation into AbstractTextSerializer and 
> removed buffer
> creation code from AbstractSerializer. The buffer created in
> AbstractSerializer was actually never used, because all subclasses of
> AbstractSerializer either didn't use super.setOutputStream() 
> or chose to
> ingore AbstractSerializer's "output" field after calling
> super.setOutputStream().
> The fixed version works for me, but please review the patch carefully.
> 
> Joerg Henne
> 


=======================================================================
Information in this email and any attachments are confidential, and may
not be copied or used by anyone other than the addressee, nor disclosed
to any third party without our permission.  There is no intention to
create any legally binding contract or other commitment through the use
of this email.

Experian Limited (registration number 653331).  
Registered office: Talbot House, Talbot Street, Nottingham NG1 5HF

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Mime
View raw message