Ok,

So, if you watch the CVS commits 4 Turbine, you would know that I'm working
on an ImageServer Screen. This Screen allows you to read an image off disk
and serve it directly through Turbine with the option to do caching of the
image data in RAM. The actual functionality of this currently is not for
discussion. ;-)

Essentially, this is the first Screen that takes advantage of data.getOut()
where we can write directly to the ServletOutputStream. The future of this
is to let other systems, like Freemarker or webmacro or cocoon take
advantage of this.

So, one issue that I just discovered after about 2 hours of looking through
code is that if I let ImageServer write directly to the outputstream, the
headers get all munged because they are written AFTER the stream has already
been written to...see Turbine.doGet().

The solution is to only attempt to write the headers if data.getPage() is
called and force anyone trying to write directly to the outputstream to set
the headers themselves. Do you all think that this is a good solution? It
allows for the most amount of flexibility in the system for people who
simply want to control everything themselves.

-jon



------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Problems?:           [EMAIL PROTECTED]

Reply via email to