You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Costin Manolache <co...@eng.sun.com> on 2000/04/16 00:36:07 UTC

BufferedServletOutputStream

BSOS has 2 bugs that I want to fix as the first step:

1. It doesn't deal with encoding when print() is called ( it just
removes the first byte ).

2. It brakes the general design of tomcat - to not allow access to more
than servlet API ( i.e. the Facade pattern). This is wrong for security
and is inconsistent with the rest of tomcat. Facade is also very useful
to isolate Servlet API semantics and rules from internal tomcat
architecture, and allow a smooth evolution.

The solution:
- add a ServletOutputStreamFacade that will be the only thing visible to
the user
- keep the buffering and notification that is part of BSOS and enhance
them to allow 0-copy output and better support for JSP. Probably we need
a better name - like
BufferedOutput.java

I will check in the 2 classes for review - without touching BSOS for
now. If anyone is using BSOS - please check if you can use the new
classes and mail me if you have problems with this change.

Both changes are bug-fixes and clean-up - let me know if you want to -1
it and propose ( and implement ) the better solution.

Similar things will need to be done for BufferedServletInputStream.

( the target is to have a clean and uniform architecture for tomcat.core
and eliminate any layering overhead )

Costin