Interface AsyncHttpClientConfig

    • Method Detail

      • getAhcVersion

        String getAhcVersion()
        Returns:
        the version of AHC
      • getThreadPoolName

        String getThreadPoolName()
        Return the name of AsyncHttpClient, which is used for thread naming and debugging.
        Returns:
        the name.
      • getMaxConnections

        int getMaxConnections()
        Return the maximum number of connections an AsyncHttpClient can handle.
        Returns:
        the maximum number of connections an AsyncHttpClient can handle.
      • getMaxConnectionsPerHost

        int getMaxConnectionsPerHost()
        Return the maximum number of connections per hosts an AsyncHttpClient can handle.
        Returns:
        the maximum number of connections per host an AsyncHttpClient can handle.
      • getAcquireFreeChannelTimeout

        int getAcquireFreeChannelTimeout()
        Return the maximum duration in milliseconds an AsyncHttpClient can wait to acquire a free channel
        Returns:
        Return the maximum duration in milliseconds an AsyncHttpClient can wait to acquire a free channel
      • getConnectTimeout

        Duration getConnectTimeout()
        Return the maximum time an AsyncHttpClient can wait when connecting to a remote host
        Returns:
        the maximum time an AsyncHttpClient can wait when connecting to a remote host
      • getPooledConnectionIdleTimeout

        Duration getPooledConnectionIdleTimeout()
        Return the maximum time an AsyncHttpClient will keep connection in pool.
        Returns:
        the maximum time an AsyncHttpClient will keep connection in pool.
      • getConnectionPoolCleanerPeriod

        Duration getConnectionPoolCleanerPeriod()
        Returns:
        the period to clean the pool of dead and idle connections.
      • getRequestTimeout

        Duration getRequestTimeout()
        Return the maximum time an AsyncHttpClient waits until the response is completed.
        Returns:
        the maximum time an AsyncHttpClient waits until the response is completed.
      • isFollowRedirect

        boolean isFollowRedirect()
        Is HTTP redirect enabled
        Returns:
        true if enabled.
      • getMaxRedirects

        int getMaxRedirects()
        Get the maximum number of HTTP redirect
        Returns:
        the maximum number of HTTP redirect
      • isKeepAlive

        boolean isKeepAlive()
        Is the ChannelPool support enabled.
        Returns:
        true if keep-alive is enabled
      • getUserAgent

        String getUserAgent()
        Return the USER_AGENT header value
        Returns:
        the USER_AGENT header value
      • isCompressionEnforced

        boolean isCompressionEnforced()
        Is HTTP compression enforced.
        Returns:
        true if compression is enforced
      • isEnableAutomaticDecompression

        boolean isEnableAutomaticDecompression()
        If automatic content decompression is enabled.
        Returns:
        true if content decompression is enabled
      • getSslContext

        @Nullable
        @Nullable io.netty.handler.ssl.SslContext getSslContext()
        Return an instance of SslContext used for SSL connection.
        Returns:
        an instance of SslContext used for SSL connection.
      • getRealm

        @Nullable
        @Nullable Realm getRealm()
        Return the current Realm
        Returns:
        the current Realm
      • getCookieStore

        CookieStore getCookieStore()
        Return cookie store that is used to store and retrieve cookies
        Returns:
        CookieStore object
      • expiredCookieEvictionDelay

        int expiredCookieEvictionDelay()
        Return the delay in milliseconds to evict expired cookies from CookieStore
        Returns:
        the delay in milliseconds to evict expired cookies from CookieStore
      • getMaxRequestRetry

        int getMaxRequestRetry()
        Return the number of time the library will retry when an IOException is throw by the remote server
        Returns:
        the number of time the library will retry when an IOException is throw by the remote server
      • isDisableUrlEncodingForBoundRequests

        boolean isDisableUrlEncodingForBoundRequests()
        Returns:
        the disableUrlEncodingForBoundRequests
      • isUseLaxCookieEncoder

        boolean isUseLaxCookieEncoder()
        Returns:
        true if AHC is to use a LAX cookie encoder, e.g. accept illegal chars in cookie value
      • isStrict302Handling

        boolean 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:
        true if strict 302 handling is to be used, otherwise false.
      • getConnectionTtl

        Duration getConnectionTtl()
        Returns:
        the maximum time an AsyncHttpClient will keep connection in the pool, or negative value to keep connection while possible.
      • isUseOpenSsl

        boolean isUseOpenSsl()
      • isUseInsecureTrustManager

        boolean isUseInsecureTrustManager()
      • isDisableHttpsEndpointIdentificationAlgorithm

        boolean 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
      • isFilterInsecureCipherSuites

        boolean isFilterInsecureCipherSuites()
        Returns:
        if insecure cipher suites must be filtered out (only used when not explicitly passing enabled cipher suites)
      • getSslSessionCacheSize

        int getSslSessionCacheSize()
        Returns:
        the size of the SSL session cache, 0 means using the default value
      • getSslSessionTimeout

        int getSslSessionTimeout()
        Returns:
        the SSL session timeout in seconds, 0 means using the default value
      • getHttpClientCodecMaxInitialLineLength

        int getHttpClientCodecMaxInitialLineLength()
      • getHttpClientCodecMaxHeaderSize

        int getHttpClientCodecMaxHeaderSize()
      • getHttpClientCodecMaxChunkSize

        int getHttpClientCodecMaxChunkSize()
      • getHttpClientCodecInitialBufferSize

        int getHttpClientCodecInitialBufferSize()
      • isDisableZeroCopy

        boolean isDisableZeroCopy()
      • getHandshakeTimeout

        int getHandshakeTimeout()
      • getSslEngineFactory

        @Nullable
        @Nullable SslEngineFactory getSslEngineFactory()
      • getChunkedFileChunkSize

        int getChunkedFileChunkSize()
      • getWebSocketMaxBufferSize

        int getWebSocketMaxBufferSize()
      • getWebSocketMaxFrameSize

        int getWebSocketMaxFrameSize()
      • isKeepEncodingHeader

        boolean isKeepEncodingHeader()
      • getShutdownQuietPeriod

        Duration getShutdownQuietPeriod()
      • getShutdownTimeout

        Duration getShutdownTimeout()
      • getChannelOptions

        Map<io.netty.channel.ChannelOption<Object>,​Object> getChannelOptions()
      • getEventLoopGroup

        @Nullable
        @Nullable io.netty.channel.EventLoopGroup getEventLoopGroup()
      • isUseNativeTransport

        boolean isUseNativeTransport()
      • isUseOnlyEpollNativeTransport

        boolean isUseOnlyEpollNativeTransport()
      • getHttpAdditionalChannelInitializer

        @Nullable
        @Nullable Consumer<io.netty.channel.Channel> getHttpAdditionalChannelInitializer()
      • getWsAdditionalChannelInitializer

        @Nullable
        @Nullable Consumer<io.netty.channel.Channel> getWsAdditionalChannelInitializer()
      • getChannelPool

        @Nullable
        @Nullable ChannelPool getChannelPool()
      • getNettyTimer

        @Nullable
        @Nullable io.netty.util.Timer getNettyTimer()
      • getHashedWheelTimerTickDuration

        long getHashedWheelTimerTickDuration()
        Returns:
        the duration between tick of HashedWheelTimer
      • getHashedWheelTimerSize

        int getHashedWheelTimerSize()
        Returns:
        the size of the hashed wheel HashedWheelTimer
      • isValidateResponseHeaders

        boolean isValidateResponseHeaders()
      • isAggregateWebSocketFrameFragments

        boolean isAggregateWebSocketFrameFragments()
      • isEnableWebSocketCompression

        boolean isEnableWebSocketCompression()
      • isTcpNoDelay

        boolean isTcpNoDelay()
      • isSoReuseAddress

        boolean isSoReuseAddress()
      • isSoKeepAlive

        boolean isSoKeepAlive()
      • getSoLinger

        int getSoLinger()
      • getSoSndBuf

        int getSoSndBuf()
      • getSoRcvBuf

        int getSoRcvBuf()
      • getAllocator

        @Nullable
        @Nullable io.netty.buffer.ByteBufAllocator getAllocator()
      • getIoThreadsCount

        int getIoThreadsCount()