On Mon, 2006-01-23 at 16:27 -0800, Craig McClanahan wrote:
> On 1/23/06, Frank W. Zammetti <[EMAIL PROTECTED]> wrote:
> > Craig McClanahan wrote:
> 
> [snip]
> 
> > > Calling flush() doesn't necessarily cause the *entire* response to be
> > > sent, because you might still be creating more output.  But it *does*
> > > cause the HTTP headers, and any output content you've written to be
> > > transmitted.  From the perspective of the servlet API, this response
> > > has now been "committed" so you cannot later decide to do a redirect
> > > or forward.
> > >
> > > In general, the only use case I can think of for calling flush()
> > > yourself is if you have something like a "Request In Progress - Please
> > > Wait" at the beginning of your page, and you want that to show to the
> > > user while a time-consuming process is performed to create the
> > > remainder of the content.
> >
> > Interesting... I would have thought just the opposite, but this makes
> > sense.  I suppose one could imagine a problem with a filter that does
> > some post-processing occurring if you flush() yourself.
> >
> 
> Yah, I suppose that's a potential use case, but I've never needed it.

If someone were to write such a filter, they should override flush() in
the wrapped response.

-Max


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

Reply via email to