From c7a52d51c0422b5ed2b5f289269d800ccf59f1d7 Mon Sep 17 00:00:00 2001 From: Oleg Kalnichevski Date: Sat, 6 May 2017 18:30:44 +0000 Subject: [PATCH] Disable HTTP tunneling support until the problem with delineation of 200 status message in response to CONNECT method has been resolved in HttpCore git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@1794172 13f79535-47bb-0310-9956-ffa450edef68 --- .../hc/client5/http/impl/async/InternalHttpAsyncClient.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/async/InternalHttpAsyncClient.java b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/async/InternalHttpAsyncClient.java index 98e5b2e8b..013e687fb 100644 --- a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/async/InternalHttpAsyncClient.java +++ b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/async/InternalHttpAsyncClient.java @@ -150,6 +150,11 @@ class InternalHttpAsyncClient extends AbstractHttpAsyncClientBase { log.debug(exchangeId + ": preparing request execution"); } + //TODO remove when fixed in HttpCore + if (route.isTunnelled()) { + throw new HttpException("HTTP tunneling not supported"); + } + setupContext(clientContext); final AsyncExecChain.Scope scope = new AsyncExecChain.Scope(exchangeId, route, request, clientContext, execRuntime);