Package org.asynchttpclient
Interface AsyncHttpClientConfig
- 
- All Known Implementing Classes:
- DefaultAsyncHttpClientConfig
 
 public interface AsyncHttpClientConfig
- 
- 
Nested Class SummaryNested Classes Modifier and Type Interface Description static classAsyncHttpClientConfig.ResponseBodyPartFactory
 - 
Method SummaryAll Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description intexpiredCookieEvictionDelay()Return the delay in milliseconds to evict expired cookies from CookieStoreintgetAcquireFreeChannelTimeout()Return the maximum duration in milliseconds anAsyncHttpClientcan wait to acquire a free channelStringgetAhcVersion()@Nullable io.netty.buffer.ByteBufAllocatorgetAllocator()Map<io.netty.channel.ChannelOption<Object>,Object>getChannelOptions()@Nullable ChannelPoolgetChannelPool()intgetChunkedFileChunkSize()DurationgetConnectionPoolCleanerPeriod()@Nullable ConnectionSemaphoreFactorygetConnectionSemaphoreFactory()DurationgetConnectionTtl()DurationgetConnectTimeout()Return the maximum time anAsyncHttpClientcan wait when connecting to a remote hostCookieStoregetCookieStore()Return cookie store that is used to store and retrieve cookies@Nullable String[]getEnabledCipherSuites()@Nullable String[]getEnabledProtocols()@Nullable io.netty.channel.EventLoopGroupgetEventLoopGroup()intgetHandshakeTimeout()intgetHashedWheelTimerSize()longgetHashedWheelTimerTickDuration()@Nullable Consumer<io.netty.channel.Channel>getHttpAdditionalChannelInitializer()intgetHttpClientCodecInitialBufferSize()intgetHttpClientCodecMaxChunkSize()intgetHttpClientCodecMaxHeaderSize()intgetHttpClientCodecMaxInitialLineLength()List<IOExceptionFilter>getIoExceptionFilters()Return the list ofIOExceptionintgetIoThreadsCount()KeepAliveStrategygetKeepAliveStrategy()intgetMaxConnections()Return the maximum number of connections anAsyncHttpClientcan handle.intgetMaxConnectionsPerHost()Return the maximum number of connections per hosts anAsyncHttpClientcan handle.intgetMaxRedirects()Get the maximum number of HTTP redirectintgetMaxRequestRetry()Return the number of time the library will retry when anIOExceptionis throw by the remote server@Nullable io.netty.util.TimergetNettyTimer()DurationgetPooledConnectionIdleTimeout()Return the maximum time anAsyncHttpClientwill keep connection in pool.ProxyServerSelectorgetProxyServerSelector()An instance ofProxyServerused by anAsyncHttpClientDurationgetReadTimeout()Return the maximum time anAsyncHttpClientcan stay idle.@Nullable RealmgetRealm()Return the currentRealmList<RequestFilter>getRequestFilters()Return the list ofRequestFilterDurationgetRequestTimeout()Return the maximum time anAsyncHttpClientwaits until the response is completed.AsyncHttpClientConfig.ResponseBodyPartFactorygetResponseBodyPartFactory()List<ResponseFilter>getResponseFilters()Return the list ofResponseFilterDurationgetShutdownQuietPeriod()DurationgetShutdownTimeout()intgetSoLinger()intgetSoRcvBuf()intgetSoSndBuf()@Nullable io.netty.handler.ssl.SslContextgetSslContext()Return an instance ofSslContextused for SSL connection.@Nullable SslEngineFactorygetSslEngineFactory()intgetSslSessionCacheSize()intgetSslSessionTimeout()@Nullable ThreadFactorygetThreadFactory()Return theThreadFactoryanAsyncHttpClientuse for handling asynchronous response.StringgetThreadPoolName()Return the name ofAsyncHttpClient, which is used for thread naming and debugging.StringgetUserAgent()Return the USER_AGENT header valueintgetWebSocketMaxBufferSize()intgetWebSocketMaxFrameSize()@Nullable Consumer<io.netty.channel.Channel>getWsAdditionalChannelInitializer()booleanisAggregateWebSocketFrameFragments()booleanisCompressionEnforced()Is HTTP compression enforced.booleanisDisableHttpsEndpointIdentificationAlgorithm()booleanisDisableUrlEncodingForBoundRequests()booleanisDisableZeroCopy()booleanisEnableAutomaticDecompression()If automatic content decompression is enabled.booleanisEnableWebSocketCompression()booleanisFilterInsecureCipherSuites()booleanisFollowRedirect()Is HTTP redirect enabledbooleanisKeepAlive()Is theChannelPoolsupport enabled.booleanisKeepEncodingHeader()booleanisSoKeepAlive()booleanisSoReuseAddress()booleanisStrict302Handling()In the case of a POST/Redirect/Get scenario where the server uses a 302 for the redirect, should AHC respond to the redirect with a GET or whatever the original method was.default booleanisStripAuthorizationOnRedirect()Indicates whether the Authorization header should be stripped during redirects to a different domain.booleanisTcpNoDelay()booleanisUseInsecureTrustManager()booleanisUseLaxCookieEncoder()booleanisUseNativeTransport()booleanisUseOnlyEpollNativeTransport()booleanisUseOpenSsl()booleanisValidateResponseHeaders()
 
- 
- 
- 
Method Detail- 
getAhcVersionString getAhcVersion() - Returns:
- the version of AHC
 
 - 
getThreadPoolNameString getThreadPoolName() Return the name ofAsyncHttpClient, which is used for thread naming and debugging.- Returns:
- the name.
 
 - 
getMaxConnectionsint getMaxConnections() Return the maximum number of connections anAsyncHttpClientcan handle.- Returns:
- the maximum number of connections an AsyncHttpClientcan handle.
 
 - 
getMaxConnectionsPerHostint getMaxConnectionsPerHost() Return the maximum number of connections per hosts anAsyncHttpClientcan handle.- Returns:
- the maximum number of connections per host an AsyncHttpClientcan handle.
 
 - 
getAcquireFreeChannelTimeoutint getAcquireFreeChannelTimeout() Return the maximum duration in milliseconds anAsyncHttpClientcan wait to acquire a free channel- Returns:
- Return the maximum duration in milliseconds an AsyncHttpClientcan wait to acquire a free channel
 
 - 
getConnectTimeoutDuration getConnectTimeout() Return the maximum time anAsyncHttpClientcan wait when connecting to a remote host- Returns:
- the maximum time an AsyncHttpClientcan wait when connecting to a remote host
 
 - 
getReadTimeoutDuration getReadTimeout() Return the maximum time anAsyncHttpClientcan stay idle.- Returns:
- the maximum time an AsyncHttpClientcan stay idle.
 
 - 
getPooledConnectionIdleTimeoutDuration getPooledConnectionIdleTimeout() Return the maximum time anAsyncHttpClientwill keep connection in pool.- Returns:
- the maximum time an AsyncHttpClientwill keep connection in pool.
 
 - 
getConnectionPoolCleanerPeriodDuration getConnectionPoolCleanerPeriod() - Returns:
- the period to clean the pool of dead and idle connections.
 
 - 
getRequestTimeoutDuration getRequestTimeout() Return the maximum time anAsyncHttpClientwaits until the response is completed.- Returns:
- the maximum time an AsyncHttpClientwaits until the response is completed.
 
 - 
isFollowRedirectboolean isFollowRedirect() Is HTTP redirect enabled- Returns:
- true if enabled.
 
 - 
getMaxRedirectsint getMaxRedirects() Get the maximum number of HTTP redirect- Returns:
- the maximum number of HTTP redirect
 
 - 
isKeepAliveboolean isKeepAlive() Is theChannelPoolsupport enabled.- Returns:
- true if keep-alive is enabled
 
 - 
getUserAgentString getUserAgent() Return the USER_AGENT header value- Returns:
- the USER_AGENT header value
 
 - 
isCompressionEnforcedboolean isCompressionEnforced() Is HTTP compression enforced.- Returns:
- true if compression is enforced
 
 - 
isEnableAutomaticDecompressionboolean isEnableAutomaticDecompression() If automatic content decompression is enabled.- Returns:
- true if content decompression is enabled
 
 - 
getThreadFactory@Nullable @Nullable ThreadFactory getThreadFactory() Return theThreadFactoryanAsyncHttpClientuse for handling asynchronous response.- Returns:
- the ThreadFactoryanAsyncHttpClientuse for handling asynchronous response. If noThreadFactoryhas been explicitly provided, this method will returnnull
 
 - 
getProxyServerSelectorProxyServerSelector getProxyServerSelector() An instance ofProxyServerused by anAsyncHttpClient- Returns:
- instance of ProxyServer
 
 - 
getSslContext@Nullable @Nullable io.netty.handler.ssl.SslContext getSslContext() Return an instance ofSslContextused for SSL connection.- Returns:
- an instance of SslContextused for SSL connection.
 
 - 
getRequestFiltersList<RequestFilter> getRequestFilters() Return the list ofRequestFilter- Returns:
- Unmodifiable list of RequestFilter
 
 - 
getResponseFiltersList<ResponseFilter> getResponseFilters() Return the list ofResponseFilter- Returns:
- Unmodifiable list of ResponseFilter
 
 - 
getIoExceptionFiltersList<IOExceptionFilter> getIoExceptionFilters() Return the list ofIOException- Returns:
- Unmodifiable list of IOException
 
 - 
getCookieStoreCookieStore getCookieStore() Return cookie store that is used to store and retrieve cookies- Returns:
- CookieStoreobject
 
 - 
expiredCookieEvictionDelayint expiredCookieEvictionDelay() Return the delay in milliseconds to evict expired cookies from CookieStore- Returns:
- the delay in milliseconds to evict expired cookies from CookieStore
 
 - 
getMaxRequestRetryint getMaxRequestRetry() Return the number of time the library will retry when anIOExceptionis throw by the remote server- Returns:
- the number of time the library will retry when an IOExceptionis throw by the remote server
 
 - 
isDisableUrlEncodingForBoundRequestsboolean isDisableUrlEncodingForBoundRequests() - Returns:
- the disableUrlEncodingForBoundRequests
 
 - 
isUseLaxCookieEncoderboolean isUseLaxCookieEncoder() - Returns:
- true if AHC is to use a LAX cookie encoder, e.g. accept illegal chars in cookie value
 
 - 
isStrict302Handlingboolean isStrict302Handling() In the case of a POST/Redirect/Get scenario where the server uses a 302 for the redirect, should AHC respond to the redirect with a GET or whatever the original method was. Unless configured otherwise, for a 302, AHC, will use a GET for this case.- Returns:
- trueif strict 302 handling is to be used, otherwise- false.
 
 - 
getConnectionTtlDuration getConnectionTtl() - Returns:
- the maximum time an AsyncHttpClientwill keep connection in the pool, or negative value to keep connection while possible.
 
 - 
isUseOpenSslboolean isUseOpenSsl() 
 - 
isUseInsecureTrustManagerboolean isUseInsecureTrustManager() 
 - 
isDisableHttpsEndpointIdentificationAlgorithmboolean isDisableHttpsEndpointIdentificationAlgorithm() - Returns:
- true to disable all HTTPS behaviors AT ONCE, such as hostname verification and SNI
 
 - 
getEnabledProtocols@Nullable @Nullable String[] getEnabledProtocols() - Returns:
- the array of enabled protocols
 
 - 
getEnabledCipherSuites@Nullable @Nullable String[] getEnabledCipherSuites() - Returns:
- the array of enabled cipher suites
 
 - 
isFilterInsecureCipherSuitesboolean isFilterInsecureCipherSuites() - Returns:
- if insecure cipher suites must be filtered out (only used when not explicitly passing enabled cipher suites)
 
 - 
getSslSessionCacheSizeint getSslSessionCacheSize() - Returns:
- the size of the SSL session cache, 0 means using the default value
 
 - 
getSslSessionTimeoutint getSslSessionTimeout() - Returns:
- the SSL session timeout in seconds, 0 means using the default value
 
 - 
getHttpClientCodecMaxInitialLineLengthint getHttpClientCodecMaxInitialLineLength() 
 - 
getHttpClientCodecMaxHeaderSizeint getHttpClientCodecMaxHeaderSize() 
 - 
getHttpClientCodecMaxChunkSizeint getHttpClientCodecMaxChunkSize() 
 - 
getHttpClientCodecInitialBufferSizeint getHttpClientCodecInitialBufferSize() 
 - 
isDisableZeroCopyboolean isDisableZeroCopy() 
 - 
getHandshakeTimeoutint getHandshakeTimeout() 
 - 
getSslEngineFactory@Nullable @Nullable SslEngineFactory getSslEngineFactory() 
 - 
getChunkedFileChunkSizeint getChunkedFileChunkSize() 
 - 
getWebSocketMaxBufferSizeint getWebSocketMaxBufferSize() 
 - 
getWebSocketMaxFrameSizeint getWebSocketMaxFrameSize() 
 - 
isKeepEncodingHeaderboolean isKeepEncodingHeader() 
 - 
getShutdownQuietPeriodDuration getShutdownQuietPeriod() 
 - 
getShutdownTimeoutDuration getShutdownTimeout() 
 - 
getEventLoopGroup@Nullable @Nullable io.netty.channel.EventLoopGroup getEventLoopGroup() 
 - 
isUseNativeTransportboolean isUseNativeTransport() 
 - 
isUseOnlyEpollNativeTransportboolean isUseOnlyEpollNativeTransport() 
 - 
getHttpAdditionalChannelInitializer@Nullable @Nullable Consumer<io.netty.channel.Channel> getHttpAdditionalChannelInitializer() 
 - 
getWsAdditionalChannelInitializer@Nullable @Nullable Consumer<io.netty.channel.Channel> getWsAdditionalChannelInitializer() 
 - 
getResponseBodyPartFactoryAsyncHttpClientConfig.ResponseBodyPartFactory getResponseBodyPartFactory() 
 - 
getChannelPool@Nullable @Nullable ChannelPool getChannelPool() 
 - 
getConnectionSemaphoreFactory@Nullable @Nullable ConnectionSemaphoreFactory getConnectionSemaphoreFactory() 
 - 
getNettyTimer@Nullable @Nullable io.netty.util.Timer getNettyTimer() 
 - 
getHashedWheelTimerTickDurationlong getHashedWheelTimerTickDuration() - Returns:
- the duration between tick of HashedWheelTimer
 
 - 
getHashedWheelTimerSizeint getHashedWheelTimerSize() - Returns:
- the size of the hashed wheel HashedWheelTimer
 
 - 
getKeepAliveStrategyKeepAliveStrategy getKeepAliveStrategy() 
 - 
isValidateResponseHeadersboolean isValidateResponseHeaders() 
 - 
isAggregateWebSocketFrameFragmentsboolean isAggregateWebSocketFrameFragments() 
 - 
isEnableWebSocketCompressionboolean isEnableWebSocketCompression() 
 - 
isTcpNoDelayboolean isTcpNoDelay() 
 - 
isSoReuseAddressboolean isSoReuseAddress() 
 - 
isSoKeepAliveboolean isSoKeepAlive() 
 - 
getSoLingerint getSoLinger() 
 - 
getSoSndBufint getSoSndBuf() 
 - 
getSoRcvBufint getSoRcvBuf() 
 - 
getAllocator@Nullable @Nullable io.netty.buffer.ByteBufAllocator getAllocator() 
 - 
getIoThreadsCountint getIoThreadsCount() 
 - 
isStripAuthorizationOnRedirectdefault boolean isStripAuthorizationOnRedirect() Indicates whether the Authorization header should be stripped during redirects to a different domain.- Returns:
- true if the Authorization header should be stripped, false otherwise.
 
 
- 
 
-