@Bean public TunnelClient remoteDebugTunnelClient( ClientHttpRequestFactory requestFactory) { RemoteDevToolsProperties remoteProperties = this.properties.getRemote(); String url = this.remoteUrl + remoteProperties.getContextPath() + "/debug"; TunnelConnection connection = new HttpTunnelConnection(url, requestFactory); int localPort = remoteProperties.getDebug().getLocalPort(); TunnelClient client = new TunnelClient(localPort, connection); client.addListener(new LoggingTunnelClientListener()); return client; }
@Bean public TunnelClient tunnelClient() { String url = "http://localhost:" + this.httpServerPort + "/httptunnel"; TunnelConnection connection = new HttpTunnelConnection(url, new SimpleClientHttpRequestFactory()); return new TunnelClient(this.clientPort, connection); }