2015-01-08 15:48 GMT+01:00 Mark Thomas <ma...@apache.org>:

> The reason I only saw the issue with NIO2 is that only NIO2 was
> buffering the ServletOutputStream for upgraded connections. The patch
> above aligned NIO2 with NIO and APR - neither of which buffer upgraded
> connections.
>
> I took a look at the spec and it wasn't completely clear if the
> ServletOutputStream in an upgraded connection should be buffered or not.
>
> Against buffering is that all of the control is on the response - which
> isn't available for an upgraded connection.
>
> For buffering is the performance benefits and that nowhere does it say
> that ServletOutputStream is not buffered for upgrade.
>
> I can see the benefits of buffering here but given the typical use of
> upgraded connections I wonder if it isn't better handled at the
> application layer as and when required. Maybe something to clarify with
> the Servlet EG?
>
> Let's assume it's fine then.

Rémy

Reply via email to