List of usage examples for com.amazonaws ClientConfiguration setUseTcpKeepAlive
public void setUseTcpKeepAlive(final boolean use)
From source file:com.amazon.kinesis.streaming.agent.AgentContext.java
License:Open Source License
public ClientConfiguration getAwsClientConfiguration() { ClientConfiguration config = new ClientConfiguration(); config.setUserAgent(userAgent(config)); config.setMaxConnections(maxConnections()); config.setConnectionTimeout(connectionTimeoutMillis()); config.setSocketTimeout(socketTimeoutMillis()); config.setUseTcpKeepAlive(useTcpKeepAlive()); config.setConnectionTTL(connectionTTLMillis()); config.setUseGzip(useHttpGzip());// w w w. j a v a2 s .com return config; }
From source file:com.smoketurner.pipeline.application.config.AwsConfiguration.java
License:Apache License
@JsonIgnore public ClientConfiguration getClientConfiguration() { final ClientConfiguration clientConfig = new ClientConfiguration(); if (proxy.isPresent()) { clientConfig.setProxyHost(proxy.get().getHostText()); clientConfig.setProxyPort(proxy.get().getPort()); }/*from www . j av a2 s . c om*/ clientConfig.setUseTcpKeepAlive(true); // needs to be false to support streaming gunzipping clientConfig.setUseGzip(false); return clientConfig; }