options.setSsl(ssl); options.setTcpNoDelay(tcpNoDelay); options.setTcpKeepAlive(tcpKeepAlive); options.setSoLinger(soLinger); options.setUsePooledBuffers(usePooledBuffers);
@Override public RestClientOptions setTcpKeepAlive(boolean tcpKeepAlive) { super.setTcpKeepAlive(tcpKeepAlive); return this; }
.setMaxPoolSize(1) .setKeepAlive(false) .setTcpKeepAlive(false);
assertEquals(options, options.setTcpKeepAlive(!tcpKeepAlive)); assertEquals(!tcpKeepAlive, options.isTcpKeepAlive());
options.setSsl(ssl); options.setTcpNoDelay(tcpNoDelay); options.setTcpKeepAlive(tcpKeepAlive); options.setSoLinger(soLinger); options.setUsePooledBuffers(usePooledBuffers);
.setMaxPoolSize(1) .setKeepAlive(false) .setTcpKeepAlive(false) .setConnectTimeout(2000);
.setMaxPoolSize(1) .setKeepAlive(false) .setTcpKeepAlive(false) .setConnectTimeout(2000);
.setMaxPoolSize(1) .setKeepAlive(false) .setTcpKeepAlive(false) .setConnectTimeout(2000);
.setMaxPoolSize(1) .setKeepAlive(false) .setTcpKeepAlive(false) .setConnectTimeout(httpClientTimeout);
.setMaxPoolSize(1) .setKeepAlive(false) .setTcpKeepAlive(false) .setConnectTimeout(httpClientTimeout);
private void createClient() { // [WebSocket <- BUS] listen BUS write to WebSocket HttpClientOptions opt = new HttpClientOptions() .setConnectTimeout(connectTimeout) // (The default value of connect timeout = 60000 ms) we set to 1 second .setTcpKeepAlive(true) .setIdleTimeout(idleTimeout) ; if(ssl_cert_key != null && ssl_cert != null && ssl_trust != null) { opt.setSsl(true) .setPemKeyCertOptions(new PemKeyCertOptions() .setKeyPath(ssl_cert_key) .setCertPath(ssl_cert) ) .setPemTrustOptions(new PemTrustOptions() .addCertPath(ssl_trust) ) ; tenant = new CertInfo(ssl_cert).getTenant(); } netClient = vertx.createHttpClient(opt); }
.setMaxPoolSize(1) .setKeepAlive(false) .setTcpKeepAlive(false);
assertEquals(options, options.setTcpKeepAlive(!tcpKeepAlive)); assertEquals(!tcpKeepAlive, options.isTcpKeepAlive());
options.setVerifyHost(false); options.setKeepAlive(true); options.setTcpKeepAlive(true);