Issue #6642 - use request UPGRADE_CONNECTION_ATTRIBUTE instead of 101 response.
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
This commit is contained in:
parent
2d4693a288
commit
edcb215ac7
|
@ -28,7 +28,6 @@ import org.eclipse.jetty.http.HttpHeader;
|
|||
import org.eclipse.jetty.http.HttpHeaderValue;
|
||||
import org.eclipse.jetty.http.HttpMethod;
|
||||
import org.eclipse.jetty.http.HttpParser;
|
||||
import org.eclipse.jetty.http.HttpStatus;
|
||||
import org.eclipse.jetty.http.MetaData;
|
||||
import org.eclipse.jetty.http.PreEncodedHttpField;
|
||||
import org.eclipse.jetty.io.AbstractConnection;
|
||||
|
@ -886,7 +885,7 @@ public class HttpConnection extends AbstractConnection implements Runnable, Http
|
|||
@Override
|
||||
protected void onCompleteSuccess()
|
||||
{
|
||||
boolean upgrading = _info != null && _info.getStatus() == HttpStatus.SWITCHING_PROTOCOLS_101;
|
||||
boolean upgrading = _channel.getRequest().getAttribute(UPGRADE_CONNECTION_ATTRIBUTE) != null;
|
||||
release().succeeded();
|
||||
// If successfully upgraded it is responsibility of the next protocol to close the connection.
|
||||
if (_shutdownOut && !upgrading)
|
||||
|
|
Loading…
Reference in New Issue