public void connectProxy(final HttpHost proxy, final boolean secure) {
        Args.notNull(proxy, "Proxy host");
        Asserts.check(!this.connected, "Already connected");
        this.connected = true;
        this.proxyChain = new HttpHost[]{proxy};
        this.secure = secure;
    }
Tracks connecting to the first proxy.

@param proxy     the proxy connected to
@param secure    {@code true} if the route is secure,
                 {@code false} otherwise
httpclient5/src/main/java/org/apache/hc/client5/http/RouteTracker.java