Graham Lea wrote:

Summary: Tomcat appears to be committing the response buffer when it is much less full (~200K) than the buffer size I have set (4MB).

I think I've made some headway...


I conjecture that the buffer size of the ServletResponse is irrelevant to a JSP - that perhaps a JSP is only concerned with the JspWriter's buffer size: that set in it's page directive.
Does anyone know if, when a JspWriter flushes, it also flushes the underlying ServletOutputStream?


It is clear that the buffer size of a JSP's Writer is not inherited by any included JSPs.
I've set a buffer size in my main JSP of 4MB, and then debugged the size of its JspWriter's buffer - 4MB: all good.
Then, I include another JSP and debug the size there - 8KB. Not good.
If, when this page gets to 8K, it commits itself, which commits the JspWriter including it, which in turn commits the ServletOutputStream, this would explain what I'm seeing.


Could someone in the know please comment on whether this seems likely? (We're talking implementation details now, I think.)

If this is the case, I can't see any solution but to set a large buffer size in all my JSPs.
Is there another solution?
In addition, if the server's going to start creating a huge buffer per JSP (rather than per request), I'm going to be in big trouble.
Is this the way the server will behave?


Any response welcome. : )

Thanks,

Graham.

--
Graham Lea
Software Engineer
Forge Research Pty Ltd
Suite G11, Bay 9, Locomotive Workshop
Australian Technology Park, Cornwallis Street
Eveleigh NSW 1430 Australia
Phone: +61 2 9209 4152   Fax: +61 2 9209 4172
www.forge.com.au
----------------------------------------------------------------------
This message contains privileged and confidential information intended
only for the use of the addressee named above.  If you are not the
intended recipient of this message you must not disseminate, copy or
take any action in reliance on it.  If you have received this message
in error please notify the sender immediately.  Any views expressed in
this message are those of the individual sender, except where the
sender specifically states them to be the views of another (including
a Body Corporate).
----------------------------------------------------------------------



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to