public class CachingWebClientOptions extends WebClientOptions
Modifier and Type | Field and Description |
---|---|
static Set<HttpMethod> |
DEFAULT_CACHED_METHODS |
static Set<Integer> |
DEFAULT_CACHED_STATUS_CODES |
DEFAULT_EXPAND_OPTIONS, DEFAULT_FOLLOW_REDIRECTS, DEFAULT_USER_AGENT, DEFAULT_USER_AGENT_ENABLED
DEFAULT_ALPN_VERSIONS, DEFAULT_DECODER_INITIAL_BUFFER_SIZE, DEFAULT_DECOMPRESSION_SUPPORTED, DEFAULT_DEFAULT_HOST, DEFAULT_DEFAULT_PORT, DEFAULT_FORCE_SNI, DEFAULT_HTTP2_CLEAR_TEXT_UPGRADE, DEFAULT_HTTP2_CLEAR_TEXT_UPGRADE_WITH_PREFLIGHT_REQUEST, DEFAULT_HTTP2_CONNECTION_WINDOW_SIZE, DEFAULT_HTTP2_KEEP_ALIVE_TIMEOUT, DEFAULT_HTTP2_MAX_POOL_SIZE, DEFAULT_HTTP2_MULTIPLEXING_LIMIT, DEFAULT_KEEP_ALIVE, DEFAULT_KEEP_ALIVE_TIMEOUT, DEFAULT_MAX_CHUNK_SIZE, DEFAULT_MAX_HEADER_SIZE, DEFAULT_MAX_INITIAL_LINE_LENGTH, DEFAULT_MAX_POOL_SIZE, DEFAULT_MAX_REDIRECTS, DEFAULT_MAX_WAIT_QUEUE_SIZE, DEFAULT_MAX_WEBSOCKET_FRAME_SIZE, DEFAULT_MAX_WEBSOCKET_MESSAGE_SIZE, DEFAULT_MAX_WEBSOCKETS, DEFAULT_NAME, DEFAULT_PIPELINING, DEFAULT_PIPELINING_LIMIT, DEFAULT_POOL_CLEANER_PERIOD, DEFAULT_POOL_EVENT_LOOP_SIZE, DEFAULT_PROTOCOL_VERSION, DEFAULT_SEND_UNMASKED_FRAMES, DEFAULT_SHARED, DEFAULT_TRACING_POLICY, DEFAULT_TRY_USE_COMPRESSION, DEFAULT_TRY_USE_PER_FRAME_WEBSOCKET_COMPRESSION, DEFAULT_TRY_USE_PER_MESSAGE_WEBSOCKET_COMPRESSION, DEFAULT_VERIFY_HOST, DEFAULT_WEBSOCKET_ALLOW_CLIENT_NO_CONTEXT, DEFAULT_WEBSOCKET_CLOSING_TIMEOUT, DEFAULT_WEBSOCKET_COMPRESSION_LEVEL, DEFAULT_WEBSOCKET_REQUEST_SERVER_NO_CONTEXT
DEFAULT_CONNECT_TIMEOUT, DEFAULT_METRICS_NAME, DEFAULT_TRUST_ALL
DEFAULT_ENABLED_SECURE_TRANSPORT_PROTOCOLS, DEFAULT_IDLE_TIMEOUT, DEFAULT_IDLE_TIMEOUT_TIME_UNIT, DEFAULT_READ_IDLE_TIMEOUT, DEFAULT_SO_LINGER, DEFAULT_SSL, DEFAULT_SSL_ENGINE, DEFAULT_SSL_HANDSHAKE_TIMEOUT, DEFAULT_SSL_HANDSHAKE_TIMEOUT_TIME_UNIT, DEFAULT_TCP_CORK, DEFAULT_TCP_FAST_OPEN, DEFAULT_TCP_KEEAPLIVE_INTERVAL_SECONDS, DEFAULT_TCP_KEEP_ALIVE, DEFAULT_TCP_KEEPALIVE_COUNT, DEFAULT_TCP_KEEPALIVE_IDLE_SECONDS, DEFAULT_TCP_NO_DELAY, DEFAULT_TCP_QUICKACK, DEFAULT_TCP_USER_TIMEOUT, DEFAULT_USE_ALPN, DEFAULT_WRITE_IDLE_TIMEOUT
DEFAULT_LOG_ACTIVITY_FORMAT, DEFAULT_LOG_ENABLED, DEFAULT_RECEIVE_BUFFER_SIZE, DEFAULT_REUSE_ADDRESS, DEFAULT_REUSE_PORT, DEFAULT_SEND_BUFFER_SIZE, DEFAULT_TRAFFIC_CLASS
Constructor and Description |
---|
CachingWebClientOptions() |
CachingWebClientOptions(boolean enableVaryCaching) |
CachingWebClientOptions(JsonObject json) |
CachingWebClientOptions(WebClientOptions other) |
Modifier and Type | Method and Description |
---|---|
CachingWebClientOptions |
addCachedMethod(HttpMethod method)
Add an HTTP method that is cacheable.
|
CachingWebClientOptions |
addCachedStatusCode(Integer code)
Add a status code that is cacheable.
|
CachingWebClientOptions |
addCrlPath(String crlPath)
Add a CRL path
|
CachingWebClientOptions |
addCrlValue(Buffer crlValue)
Add a CRL value
|
CachingWebClientOptions |
addEnabledCipherSuite(String suite)
Add an enabled cipher suite, appended to the ordered suites.
|
CachingWebClientOptions |
addEnabledSecureTransportProtocol(String protocol)
Add an enabled SSL/TLS protocols, appended to the ordered protocols.
|
Set<HttpMethod> |
getCachedMethods() |
Set<Integer> |
getCachedStatusCodes() |
boolean |
isVaryCachingEnabled() |
CachingWebClientOptions |
removeCachedMethod(HttpMethod method)
Remove an HTTP method that is cacheable.
|
CachingWebClientOptions |
removeCachedStatusCode(Integer code)
Remove a status code that is cacheable.
|
CachingWebClientOptions |
removeEnabledSecureTransportProtocol(String protocol)
Removes an enabled SSL/TLS protocol from the ordered protocols.
|
CachingWebClientOptions |
setAlpnVersions(List<HttpVersion> alpnVersions)
Set the list of protocol versions to provide to the server during the Application-Layer Protocol Negotiation.
|
CachingWebClientOptions |
setCachedMethods(Set<HttpMethod> methods)
Configure the HTTP methods that can be cached.
|
CachingWebClientOptions |
setCachedStatusCodes(Set<Integer> codes)
Configure the status codes that can be cached.
|
CachingWebClientOptions |
setConnectTimeout(int connectTimeout)
Set the connect timeout
|
CachingWebClientOptions |
setDecoderInitialBufferSize(int decoderInitialBufferSize)
set to
initialBufferSizeHttpDecoder the initial buffer of the HttpDecoder. |
CachingWebClientOptions |
setDecompressionSupported(boolean tryUseCompression)
Whether the client should send requests with an
accepting-encoding header set to a compression algorithm. |
CachingWebClientOptions |
setDefaultHost(String defaultHost)
Set the default host name to be used by this client in requests if none is provided when making the request.
|
CachingWebClientOptions |
setDefaultPort(int defaultPort)
Set the default port to be used by this client in requests if none is provided when making the request.
|
CachingWebClientOptions |
setEnabledSecureTransportProtocols(Set<String> enabledSecureTransportProtocols)
Sets the list of enabled SSL/TLS protocols.
|
CachingWebClientOptions |
setEnableVaryCaching(boolean enabled)
Configure the client cache behavior for
Vary responses. |
CachingWebClientOptions |
setFollowRedirects(boolean followRedirects)
Configure the default behavior of the client to follow HTTP
30x redirections. |
CachingWebClientOptions |
setForceSni(boolean forceSni)
By default, the server name is only sent for Fully Qualified Domain Name (FQDN), setting
this property to
true forces the server name to be always sent. |
CachingWebClientOptions |
setHttp2ClearTextUpgrade(boolean value)
Set to
true when an h2c connection is established using an HTTP/1.1 upgrade request, and false
when an h2c connection is established directly (with prior knowledge). |
CachingWebClientOptions |
setHttp2ConnectionWindowSize(int http2ConnectionWindowSize)
Set the default HTTP/2 connection window size.
|
CachingWebClientOptions |
setHttp2KeepAliveTimeout(int keepAliveTimeout)
Set the keep alive timeout for HTTP/2 connections, in seconds.
|
CachingWebClientOptions |
setHttp2MaxPoolSize(int max)
Set the maximum pool size for HTTP/2 connections
|
CachingWebClientOptions |
setHttp2MultiplexingLimit(int limit)
Set a client limit of the number concurrent streams for each HTTP/2 connection, this limits the number
of streams the client can create for a connection.
|
CachingWebClientOptions |
setIdleTimeout(int idleTimeout)
Set the idle timeout, default time unit is seconds.
|
CachingWebClientOptions |
setIdleTimeoutUnit(TimeUnit idleTimeoutUnit)
Set the idle timeout unit.
|
CachingWebClientOptions |
setInitialSettings(Http2Settings settings)
Set the HTTP/2 connection settings immediately sent by to the server when the client connects.
|
CachingWebClientOptions |
setJdkSslEngineOptions(JdkSSLEngineOptions sslEngineOptions) |
CachingWebClientOptions |
setKeepAlive(boolean keepAlive)
Set whether keep alive is enabled on the client
|
CachingWebClientOptions |
setKeepAliveTimeout(int keepAliveTimeout)
Set the keep alive timeout for HTTP/1.x, in seconds.
|
CachingWebClientOptions |
setKeyCertOptions(KeyCertOptions options)
Set the key/cert options.
|
CachingWebClientOptions |
setKeyStoreOptions(JksOptions options)
Set the key/cert options in jks format, aka Java keystore.
|
CachingWebClientOptions |
setLocalAddress(String localAddress)
Set the local interface to bind for network connections.
|
CachingWebClientOptions |
setLogActivity(boolean logEnabled)
Set to true to enabled network activity logging: Netty's pipeline is configured for logging on Netty's logger.
|
CachingWebClientOptions |
setMaxChunkSize(int maxChunkSize)
Set the maximum HTTP chunk size
|
CachingWebClientOptions |
setMaxHeaderSize(int maxHeaderSize)
Set the maximum length of all headers for HTTP/1.x .
|
CachingWebClientOptions |
setMaxInitialLineLength(int maxInitialLineLength)
Set the maximum length of the initial line for HTTP/1.x (e.g.
|
CachingWebClientOptions |
setMaxPoolSize(int maxPoolSize)
Set the maximum pool size for connections
|
CachingWebClientOptions |
setMaxRedirects(int maxRedirects)
Set to
maxRedirects the maximum number of redirection a request can follow. |
CachingWebClientOptions |
setMaxWaitQueueSize(int maxWaitQueueSize)
Set the maximum requests allowed in the wait queue, any requests beyond the max size will result in
a ConnectionPoolTooBusyException.
|
CachingWebClientOptions |
setMaxWebSocketFrameSize(int maxWebsocketFrameSize)
Set the max WebSocket frame size
|
CachingWebClientOptions |
setMaxWebSocketMessageSize(int maxWebsocketMessageSize)
Set the max WebSocket message size
|
CachingWebClientOptions |
setMetricsName(String metricsName)
Set the metrics name identifying the reported metrics, useful for grouping metrics
with the same name.
|
CachingWebClientOptions |
setOpenSslEngineOptions(OpenSSLEngineOptions sslEngineOptions) |
CachingWebClientOptions |
setPemKeyCertOptions(PemKeyCertOptions options)
Set the key/cert store options in pem format.
|
CachingWebClientOptions |
setPemTrustOptions(PemTrustOptions options)
Set the trust options in pem format
|
CachingWebClientOptions |
setPfxKeyCertOptions(PfxOptions options)
Set the key/cert options in pfx format.
|
CachingWebClientOptions |
setPfxTrustOptions(PfxOptions options)
Set the trust options in pfx format
|
CachingWebClientOptions |
setPipelining(boolean pipelining)
Set whether pipe-lining is enabled on the client
|
CachingWebClientOptions |
setPipeliningLimit(int limit)
Set the limit of pending requests a pipe-lined HTTP/1 connection can send.
|
CachingWebClientOptions |
setPoolCleanerPeriod(int poolCleanerPeriod)
Set the connection pool cleaner period in milli seconds, a non positive value disables expiration checks and connections
will remain in the pool until they are closed.
|
CachingWebClientOptions |
setProtocolVersion(HttpVersion protocolVersion)
Set the protocol version.
|
CachingWebClientOptions |
setProxyOptions(ProxyOptions proxyOptions)
Set proxy options for connections via CONNECT proxy (e.g.
|
CachingWebClientOptions |
setReceiveBufferSize(int receiveBufferSize)
Set the TCP receive buffer size
|
CachingWebClientOptions |
setReuseAddress(boolean reuseAddress)
Set the value of reuse address
|
CachingWebClientOptions |
setReusePort(boolean reusePort)
Set the value of reuse port.
|
CachingWebClientOptions |
setSendBufferSize(int sendBufferSize)
Set the TCP send buffer size
|
CachingWebClientOptions |
setSendUnmaskedFrames(boolean sendUnmaskedFrames)
Set
true when the client wants to skip frame masking. |
CachingWebClientOptions |
setSoLinger(int soLinger)
Set whether SO_linger keep alive is enabled
|
CachingWebClientOptions |
setSsl(boolean ssl)
Set whether SSL/TLS is enabled
|
CachingWebClientOptions |
setSslEngineOptions(SSLEngineOptions sslEngineOptions)
Set to use SSL engine implementation to use.
|
CachingWebClientOptions |
setSslHandshakeTimeout(long sslHandshakeTimeout)
Set the SSL handshake timeout, default time unit is seconds.
|
CachingWebClientOptions |
setSslHandshakeTimeoutUnit(TimeUnit sslHandshakeTimeoutUnit)
Set the SSL handshake timeout unit.
|
CachingWebClientOptions |
setTcpCork(boolean tcpCork)
Enable the
TCP_CORK option - only with linux native transport. |
CachingWebClientOptions |
setTcpFastOpen(boolean tcpFastOpen)
Enable the
TCP_FASTOPEN option - only with linux native transport. |
CachingWebClientOptions |
setTcpKeepAlive(boolean tcpKeepAlive)
Set whether TCP keep alive is enabled
|
CachingWebClientOptions |
setTcpNoDelay(boolean tcpNoDelay)
Set whether TCP no delay is enabled
|
CachingWebClientOptions |
setTcpQuickAck(boolean tcpQuickAck)
Enable the
TCP_QUICKACK option - only with linux native transport. |
CachingWebClientOptions |
setTrafficClass(int trafficClass)
Set the value of traffic class
|
CachingWebClientOptions |
setTrustAll(boolean trustAll)
Set whether all server certificates should be trusted
|
CachingWebClientOptions |
setTrustOptions(TrustOptions options)
Set the trust options.
|
CachingWebClientOptions |
setTrustStoreOptions(JksOptions options)
Set the trust options in jks format, aka Java truststore
|
CachingWebClientOptions |
setTryUseCompression(boolean tryUseCompression)
Deprecated.
|
CachingWebClientOptions |
setTryUsePerFrameWebSocketCompression(boolean offer)
Set whether the client will offer the WebSocket per-frame deflate compression extension.
|
CachingWebClientOptions |
setTryUsePerMessageWebSocketCompression(boolean offer)
Set whether the client will offer the WebSocket per-message deflate compression extension.
|
CachingWebClientOptions |
setUseAlpn(boolean useAlpn)
Set the ALPN usage.
|
CachingWebClientOptions |
setUserAgent(String userAgent)
Sets the Web Client user agent header.
|
CachingWebClientOptions |
setUserAgentEnabled(boolean userAgentEnabled)
Sets whether the Web Client should send a user agent header.
|
CachingWebClientOptions |
setVerifyHost(boolean verifyHost)
Set whether hostname verification is enabled
|
CachingWebClientOptions |
setWebSocketCompressionAllowClientNoContext(boolean offer)
Set whether the
client_no_context_takeover parameter of the WebSocket per-message
deflate compression extension will be offered. |
CachingWebClientOptions |
setWebSocketCompressionLevel(int compressionLevel)
Set the WebSocket deflate compression level.
|
CachingWebClientOptions |
setWebSocketCompressionRequestServerNoContext(boolean offer)
Set whether the
server_no_context_takeover parameter of the WebSocket per-message
deflate compression extension will be offered. |
JsonObject |
toJson()
Convert to JSON
|
addNonProxyHost, getTemplateExpandOptions, getUserAgent, isFollowRedirects, isUserAgentEnabled, loadUserAgent, setMaxWebSockets, setName, setNonProxyHosts, setPoolEventLoopSize, setReadIdleTimeout, setShared, setTemplateExpandOptions, setTracingPolicy, setWebSocketClosingTimeout, setWriteIdleTimeout
getAlpnVersions, getDecoderInitialBufferSize, getDefaultHost, getDefaultPort, getHttp2ConnectionWindowSize, getHttp2KeepAliveTimeout, getHttp2MaxPoolSize, getHttp2MultiplexingLimit, getInitialSettings, getKeepAliveTimeout, getMaxChunkSize, getMaxHeaderSize, getMaxInitialLineLength, getMaxPoolSize, getMaxRedirects, getMaxWaitQueueSize, getMaxWebSocketFrameSize, getMaxWebSocketMessageSize, getMaxWebSockets, getName, getPipeliningLimit, getPoolCleanerPeriod, getPoolEventLoopSize, getPoolOptions, getProtocolVersion, getTracingPolicy, getTryUsePerFrameWebSocketCompression, getTryUsePerMessageWebSocketCompression, getTryWebSocketDeflateFrameCompression, getWebSocketClosingTimeout, getWebSocketCompressionAllowClientNoContext, getWebSocketCompressionLevel, getWebSocketCompressionRequestServerNoContext, isDecompressionSupported, isForceSni, isHttp2ClearTextUpgrade, isHttp2ClearTextUpgradeWithPreflightRequest, isKeepAlive, isPipelining, isSendUnmaskedFrames, isShared, isTryUseCompression, isVerifyHost, removeEnabledCipherSuite, setActivityLogDataFormat, setHttp2ClearTextUpgradeWithPreflightRequest, setTcpUserTimeout
getConnectTimeout, getLocalAddress, getMetricsName, getNonProxyHosts, getProxyOptions, isTrustAll
getCrlPaths, getCrlValues, getEnabledCipherSuites, getEnabledSecureTransportProtocols, getIdleTimeout, getIdleTimeoutUnit, getJdkSslEngineOptions, getKeyCertOptions, getKeyStoreOptions, getOpenSslEngineOptions, getPemKeyCertOptions, getPemTrustOptions, getPfxKeyCertOptions, getPfxTrustOptions, getReadIdleTimeout, getSoLinger, getSslEngineOptions, getSslHandshakeTimeout, getSslHandshakeTimeoutUnit, getSslOptions, getTcpKeepAliveCount, getTcpKeepAliveIdleSeconds, getTcpKeepAliveIntervalSeconds, getTcpUserTimeout, getTrustOptions, getTrustStoreOptions, getWriteIdleTimeout, isSsl, isTcpCork, isTcpFastOpen, isTcpKeepAlive, isTcpNoDelay, isTcpQuickAck, isUseAlpn, setTcpKeepAliveCount, setTcpKeepAliveIdleSeconds, setTcpKeepAliveIntervalSeconds
getActivityLogDataFormat, getLogActivity, getReceiveBufferSize, getSendBufferSize, getTrafficClass, isReuseAddress, isReusePort
public static final Set<HttpMethod> DEFAULT_CACHED_METHODS
public CachingWebClientOptions()
public CachingWebClientOptions(boolean enableVaryCaching)
public CachingWebClientOptions(WebClientOptions other)
public CachingWebClientOptions(JsonObject json)
public JsonObject toJson()
toJson
in class WebClientOptions
public CachingWebClientOptions setEnableVaryCaching(boolean enabled)
Vary
responses.enabled
- true to enable caching varying responsespublic Set<Integer> getCachedStatusCodes()
public CachingWebClientOptions setCachedStatusCodes(Set<Integer> codes)
codes
- the cacheable status code numberspublic CachingWebClientOptions addCachedStatusCode(Integer code)
code
- the additional code numberpublic CachingWebClientOptions removeCachedStatusCode(Integer code)
code
- the code number to removepublic Set<HttpMethod> getCachedMethods()
public CachingWebClientOptions setCachedMethods(Set<HttpMethod> methods)
methods
- the HTTP methods to cachepublic CachingWebClientOptions addCachedMethod(HttpMethod method)
method
- the method to addpublic CachingWebClientOptions removeCachedMethod(HttpMethod method)
method
- the method to removepublic boolean isVaryCachingEnabled()
Vary
header, false otherwisepublic CachingWebClientOptions setUserAgentEnabled(boolean userAgentEnabled)
WebClientOptions
setUserAgentEnabled
in class WebClientOptions
userAgentEnabled
- true to send a user agent header, false otherwisepublic CachingWebClientOptions setUserAgent(String userAgent)
WebClientOptions
setUserAgent
in class WebClientOptions
userAgent
- user agent header valuepublic CachingWebClientOptions setFollowRedirects(boolean followRedirects)
WebClientOptions
30x
redirections.setFollowRedirects
in class WebClientOptions
followRedirects
- true when a redirect is followedpublic CachingWebClientOptions setMaxRedirects(int maxRedirects)
HttpClientOptions
maxRedirects
the maximum number of redirection a request can follow.setMaxRedirects
in class WebClientOptions
maxRedirects
- the maximum number of redirectionpublic CachingWebClientOptions setSendBufferSize(int sendBufferSize)
NetworkOptions
setSendBufferSize
in class WebClientOptions
sendBufferSize
- the buffers size, in bytespublic CachingWebClientOptions setReceiveBufferSize(int receiveBufferSize)
NetworkOptions
setReceiveBufferSize
in class WebClientOptions
receiveBufferSize
- the buffers size, in bytespublic CachingWebClientOptions setReuseAddress(boolean reuseAddress)
NetworkOptions
setReuseAddress
in class WebClientOptions
reuseAddress
- the value of reuse addresspublic CachingWebClientOptions setTrafficClass(int trafficClass)
NetworkOptions
setTrafficClass
in class WebClientOptions
trafficClass
- the value of traffic classpublic CachingWebClientOptions setTcpNoDelay(boolean tcpNoDelay)
TCPSSLOptions
setTcpNoDelay
in class WebClientOptions
tcpNoDelay
- true if TCP no delay is enabled (Nagle disabled)public CachingWebClientOptions setTcpKeepAlive(boolean tcpKeepAlive)
TCPSSLOptions
setTcpKeepAlive
in class WebClientOptions
tcpKeepAlive
- true if TCP keep alive is enabledpublic CachingWebClientOptions setSoLinger(int soLinger)
TCPSSLOptions
setSoLinger
in class WebClientOptions
soLinger
- true if SO_linger is enabledpublic CachingWebClientOptions setIdleTimeout(int idleTimeout)
TCPSSLOptions
TCPSSLOptions.setIdleTimeoutUnit(TimeUnit)
setIdleTimeout
in class WebClientOptions
idleTimeout
- the timeoutpublic CachingWebClientOptions setIdleTimeoutUnit(TimeUnit idleTimeoutUnit)
TCPSSLOptions
setIdleTimeoutUnit
in class WebClientOptions
idleTimeoutUnit
- specify time unit.public CachingWebClientOptions setSsl(boolean ssl)
TCPSSLOptions
setSsl
in class WebClientOptions
ssl
- true if enabledpublic CachingWebClientOptions setKeyCertOptions(KeyCertOptions options)
TCPSSLOptions
setKeyCertOptions
in class WebClientOptions
options
- the key store optionspublic CachingWebClientOptions setKeyStoreOptions(JksOptions options)
TCPSSLOptions
setKeyStoreOptions
in class WebClientOptions
options
- the key store in jks formatpublic CachingWebClientOptions setPfxKeyCertOptions(PfxOptions options)
TCPSSLOptions
setPfxKeyCertOptions
in class WebClientOptions
options
- the key cert options in pfx formatpublic CachingWebClientOptions setTrustOptions(TrustOptions options)
TCPSSLOptions
setTrustOptions
in class WebClientOptions
options
- the trust optionspublic CachingWebClientOptions setPemKeyCertOptions(PemKeyCertOptions options)
TCPSSLOptions
setPemKeyCertOptions
in class WebClientOptions
options
- the options in pem formatpublic CachingWebClientOptions setTrustStoreOptions(JksOptions options)
TCPSSLOptions
setTrustStoreOptions
in class WebClientOptions
options
- the trust options in jks formatpublic CachingWebClientOptions setPfxTrustOptions(PfxOptions options)
TCPSSLOptions
setPfxTrustOptions
in class WebClientOptions
options
- the trust options in pfx formatpublic CachingWebClientOptions setPemTrustOptions(PemTrustOptions options)
TCPSSLOptions
setPemTrustOptions
in class WebClientOptions
options
- the trust options in pem formatpublic CachingWebClientOptions addEnabledCipherSuite(String suite)
TCPSSLOptions
addEnabledCipherSuite
in class WebClientOptions
suite
- the suiteTCPSSLOptions.getEnabledCipherSuites()
public CachingWebClientOptions addCrlPath(String crlPath) throws NullPointerException
TCPSSLOptions
addCrlPath
in class WebClientOptions
crlPath
- the pathNullPointerException
public CachingWebClientOptions addCrlValue(Buffer crlValue) throws NullPointerException
TCPSSLOptions
addCrlValue
in class WebClientOptions
crlValue
- the valueNullPointerException
public CachingWebClientOptions setConnectTimeout(int connectTimeout)
ClientOptionsBase
setConnectTimeout
in class WebClientOptions
connectTimeout
- connect timeout, in mspublic CachingWebClientOptions setTrustAll(boolean trustAll)
ClientOptionsBase
setTrustAll
in class WebClientOptions
trustAll
- true if all should be trustedpublic CachingWebClientOptions setMaxPoolSize(int maxPoolSize)
HttpClientOptions
setMaxPoolSize
in class WebClientOptions
maxPoolSize
- the maximum pool sizepublic CachingWebClientOptions setHttp2MultiplexingLimit(int limit)
HttpClientOptions
-1
means to use the value sent by the server's initial settings.
-1
is the default value.setHttp2MultiplexingLimit
in class WebClientOptions
limit
- the maximum concurrent for an HTTP/2 connectionpublic CachingWebClientOptions setHttp2MaxPoolSize(int max)
HttpClientOptions
setHttp2MaxPoolSize
in class WebClientOptions
max
- the maximum pool sizepublic CachingWebClientOptions setHttp2ConnectionWindowSize(int http2ConnectionWindowSize)
HttpClientOptions
Http2Settings.getInitialWindowSize()
, so the connection window size
is greater than for its streams, in order the data throughput.
A value of -1
reuses the initial window size setting.setHttp2ConnectionWindowSize
in class WebClientOptions
http2ConnectionWindowSize
- the window size applied to the connectionpublic CachingWebClientOptions setKeepAlive(boolean keepAlive)
HttpClientOptions
setKeepAlive
in class WebClientOptions
keepAlive
- true
if enabledpublic CachingWebClientOptions setPipelining(boolean pipelining)
HttpClientOptions
setPipelining
in class WebClientOptions
pipelining
- true
if enabledpublic CachingWebClientOptions setPipeliningLimit(int limit)
HttpClientOptions
setPipeliningLimit
in class WebClientOptions
limit
- the limit of pending requestspublic CachingWebClientOptions setVerifyHost(boolean verifyHost)
HttpClientOptions
setVerifyHost
in class WebClientOptions
verifyHost
- true
if enabled@Deprecated public CachingWebClientOptions setTryUseCompression(boolean tryUseCompression)
HttpClientOptions
setTryUseCompression
in class WebClientOptions
tryUseCompression
- true
if enabledpublic CachingWebClientOptions setDecompressionSupported(boolean tryUseCompression)
HttpClientOptions
accepting-encoding
header set to a compression algorithm.setDecompressionSupported
in class WebClientOptions
tryUseCompression
- true
if the client should send a request with an accepting-encoding
header set to a compression algorithm, false
otherwisepublic CachingWebClientOptions setSendUnmaskedFrames(boolean sendUnmaskedFrames)
HttpClientOptions
true
when the client wants to skip frame masking.
You may want to set it true
on server by server WebSocket communication: in this case you are by passing
RFC6455 protocol.
It's false
as default.
setSendUnmaskedFrames
in class WebClientOptions
sendUnmaskedFrames
- true if enabledpublic CachingWebClientOptions setMaxWebSocketFrameSize(int maxWebsocketFrameSize)
HttpClientOptions
setMaxWebSocketFrameSize
in class WebClientOptions
maxWebsocketFrameSize
- the max frame size, in bytespublic CachingWebClientOptions setDefaultHost(String defaultHost)
HttpClientOptions
setDefaultHost
in class WebClientOptions
public CachingWebClientOptions setDefaultPort(int defaultPort)
HttpClientOptions
setDefaultPort
in class WebClientOptions
public CachingWebClientOptions setMaxChunkSize(int maxChunkSize)
HttpClientOptions
setMaxChunkSize
in class WebClientOptions
maxChunkSize
- the maximum chunk sizepublic CachingWebClientOptions setProtocolVersion(HttpVersion protocolVersion)
HttpClientOptions
setProtocolVersion
in class WebClientOptions
protocolVersion
- the protocol versionpublic CachingWebClientOptions setMaxHeaderSize(int maxHeaderSize)
HttpClientOptions
setMaxHeaderSize
in class WebClientOptions
maxHeaderSize
- the new maximum lengthpublic CachingWebClientOptions setMaxWaitQueueSize(int maxWaitQueueSize)
HttpClientOptions
setMaxWaitQueueSize
in class WebClientOptions
maxWaitQueueSize
- the maximum number of waiting requestspublic CachingWebClientOptions setUseAlpn(boolean useAlpn)
TCPSSLOptions
setUseAlpn
in class WebClientOptions
useAlpn
- true when Application-Layer Protocol Negotiation should be usedpublic CachingWebClientOptions setSslEngineOptions(SSLEngineOptions sslEngineOptions)
TCPSSLOptions
setSslEngineOptions
in class WebClientOptions
sslEngineOptions
- the ssl engine to usepublic CachingWebClientOptions setJdkSslEngineOptions(JdkSSLEngineOptions sslEngineOptions)
setJdkSslEngineOptions
in class WebClientOptions
public CachingWebClientOptions setOpenSslEngineOptions(OpenSSLEngineOptions sslEngineOptions)
setOpenSslEngineOptions
in class WebClientOptions
public CachingWebClientOptions setHttp2ClearTextUpgrade(boolean value)
HttpClientOptions
true
when an h2c connection is established using an HTTP/1.1 upgrade request, and false
when an h2c connection is established directly (with prior knowledge).setHttp2ClearTextUpgrade
in class WebClientOptions
value
- the upgrade valuepublic CachingWebClientOptions setAlpnVersions(List<HttpVersion> alpnVersions)
HttpClientOptions
HttpClientOptions.setProtocolVersion(io.vertx.core.http.HttpVersion)
:
HttpVersion.HTTP_2
: [ "h2", "http/1.1" ]HttpClientOptions.getProtocolVersion()
]setAlpnVersions
in class WebClientOptions
alpnVersions
- the versionspublic CachingWebClientOptions setMetricsName(String metricsName)
ClientOptionsBase
setMetricsName
in class WebClientOptions
metricsName
- the metrics namepublic CachingWebClientOptions setProxyOptions(ProxyOptions proxyOptions)
ClientOptionsBase
setProxyOptions
in class WebClientOptions
proxyOptions
- proxy options objectpublic CachingWebClientOptions setLocalAddress(String localAddress)
ClientOptionsBase
setLocalAddress
in class WebClientOptions
localAddress
- the local addresspublic CachingWebClientOptions setLogActivity(boolean logEnabled)
NetworkOptions
setLogActivity
in class WebClientOptions
logEnabled
- true for logging the network activitypublic CachingWebClientOptions addEnabledSecureTransportProtocol(String protocol)
TCPSSLOptions
addEnabledSecureTransportProtocol
in class WebClientOptions
protocol
- the SSL/TLS protocol to enablepublic CachingWebClientOptions removeEnabledSecureTransportProtocol(String protocol)
TCPSSLOptions
removeEnabledSecureTransportProtocol
in class WebClientOptions
protocol
- the SSL/TLS protocol to disablepublic CachingWebClientOptions setEnabledSecureTransportProtocols(Set<String> enabledSecureTransportProtocols)
TCPSSLOptions
setEnabledSecureTransportProtocols
in class WebClientOptions
enabledSecureTransportProtocols
- the SSL/TLS protocols to enablepublic CachingWebClientOptions setReusePort(boolean reusePort)
NetworkOptions
setReusePort
in class WebClientOptions
reusePort
- the value of reuse portpublic CachingWebClientOptions setTcpFastOpen(boolean tcpFastOpen)
TCPSSLOptions
TCP_FASTOPEN
option - only with linux native transport.setTcpFastOpen
in class WebClientOptions
tcpFastOpen
- the fast open valuepublic CachingWebClientOptions setTcpCork(boolean tcpCork)
TCPSSLOptions
TCP_CORK
option - only with linux native transport.setTcpCork
in class WebClientOptions
tcpCork
- the cork valuepublic CachingWebClientOptions setTcpQuickAck(boolean tcpQuickAck)
TCPSSLOptions
TCP_QUICKACK
option - only with linux native transport.setTcpQuickAck
in class WebClientOptions
tcpQuickAck
- the quick ack valuepublic CachingWebClientOptions setHttp2KeepAliveTimeout(int keepAliveTimeout)
HttpClientOptions
0
means there is no timeout.setHttp2KeepAliveTimeout
in class WebClientOptions
keepAliveTimeout
- the timeout, in secondspublic CachingWebClientOptions setForceSni(boolean forceSni)
HttpClientOptions
true
forces the server name to be always sent.setForceSni
in class WebClientOptions
forceSni
- true
when the client should always use SNI on TLS/SSL connectionspublic CachingWebClientOptions setDecoderInitialBufferSize(int decoderInitialBufferSize)
HttpClientOptions
initialBufferSizeHttpDecoder
the initial buffer of the HttpDecoder.setDecoderInitialBufferSize
in class WebClientOptions
decoderInitialBufferSize
- the initial buffer sizepublic CachingWebClientOptions setPoolCleanerPeriod(int poolCleanerPeriod)
HttpClientOptions
setPoolCleanerPeriod
in class WebClientOptions
poolCleanerPeriod
- the pool cleaner periodpublic CachingWebClientOptions setKeepAliveTimeout(int keepAliveTimeout)
HttpClientOptions
0
means there is no timeout.setKeepAliveTimeout
in class WebClientOptions
keepAliveTimeout
- the timeout, in secondspublic CachingWebClientOptions setMaxWebSocketMessageSize(int maxWebsocketMessageSize)
HttpClientOptions
setMaxWebSocketMessageSize
in class WebClientOptions
maxWebsocketMessageSize
- the max message size, in bytespublic CachingWebClientOptions setMaxInitialLineLength(int maxInitialLineLength)
HttpClientOptions
"HTTP/1.1 200 OK"
)setMaxInitialLineLength
in class WebClientOptions
maxInitialLineLength
- the new maximum initial lengthpublic CachingWebClientOptions setInitialSettings(Http2Settings settings)
HttpClientOptions
setInitialSettings
in class WebClientOptions
settings
- the settings valuepublic CachingWebClientOptions setSslHandshakeTimeout(long sslHandshakeTimeout)
TCPSSLOptions
setSslHandshakeTimeout
in class WebClientOptions
sslHandshakeTimeout
- the SSL handshake timeout to set, in millisecondspublic CachingWebClientOptions setSslHandshakeTimeoutUnit(TimeUnit sslHandshakeTimeoutUnit)
TCPSSLOptions
setSslHandshakeTimeoutUnit
in class WebClientOptions
sslHandshakeTimeoutUnit
- specify time unit.public CachingWebClientOptions setTryUsePerFrameWebSocketCompression(boolean offer)
HttpClientOptions
setTryUsePerFrameWebSocketCompression
in class WebClientOptions
offer
- true
to offer the per-frame deflate compression extensionpublic CachingWebClientOptions setTryUsePerMessageWebSocketCompression(boolean offer)
HttpClientOptions
setTryUsePerMessageWebSocketCompression
in class WebClientOptions
offer
- true
to offer the per-message deflate compression extensionpublic CachingWebClientOptions setWebSocketCompressionLevel(int compressionLevel)
HttpClientOptions
setWebSocketCompressionLevel
in class WebClientOptions
compressionLevel
- the WebSocket deflate compression levelpublic CachingWebClientOptions setWebSocketCompressionAllowClientNoContext(boolean offer)
HttpClientOptions
client_no_context_takeover
parameter of the WebSocket per-message
deflate compression extension will be offered.setWebSocketCompressionAllowClientNoContext
in class WebClientOptions
offer
- true
to offer the client_no_context_takeover
parameterpublic CachingWebClientOptions setWebSocketCompressionRequestServerNoContext(boolean offer)
HttpClientOptions
server_no_context_takeover
parameter of the WebSocket per-message
deflate compression extension will be offered.setWebSocketCompressionRequestServerNoContext
in class WebClientOptions
offer
- true
to offer the server_no_context_takeover
parameterCopyright © 2024 Eclipse. All rights reserved.