Class CachingHttpAsyncClients


  • public final class CachingHttpAsyncClients
    extends java.lang.Object
    Factory methods for CloseableHttpAsyncClient instances capable of client-side caching.
    Since:
    5.0
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static org.apache.hc.client5.http.impl.async.CloseableHttpAsyncClient createFileBound​(java.io.File cacheDir)
      Creates CloseableHttpAsyncClient instance that uses a file system bound response cache.
      static org.apache.hc.client5.http.impl.async.CloseableHttpAsyncClient createHttp2FileBound​(java.io.File cacheDir)
      Creates HTTP/2 CloseableHttpAsyncClient instance that uses a file system bound response cache.
      static org.apache.hc.client5.http.impl.async.CloseableHttpAsyncClient createHttp2MemoryBound()
      Creates HTTP/2 CloseableHttpAsyncClient instance that uses a memory bound response cache.
      static org.apache.hc.client5.http.impl.async.CloseableHttpAsyncClient createMemoryBound()
      Creates CloseableHttpAsyncClient instance that uses a memory bound response cache.
      static CachingHttpAsyncClientBuilder custom()
      Creates builder object for construction of custom CloseableHttpAsyncClient instances.
      static CachingH2AsyncClientBuilder customHttp2()
      Creates builder object for construction of custom HTTP/2 CloseableHttpAsyncClient instances.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • custom

        public static CachingHttpAsyncClientBuilder custom()
        Creates builder object for construction of custom CloseableHttpAsyncClient instances.
      • createMemoryBound

        public static org.apache.hc.client5.http.impl.async.CloseableHttpAsyncClient createMemoryBound()
        Creates CloseableHttpAsyncClient instance that uses a memory bound response cache.
      • createFileBound

        public static org.apache.hc.client5.http.impl.async.CloseableHttpAsyncClient createFileBound​(java.io.File cacheDir)
        Creates CloseableHttpAsyncClient instance that uses a file system bound response cache.
        Parameters:
        cacheDir - location of response cache.
      • customHttp2

        public static CachingH2AsyncClientBuilder customHttp2()
        Creates builder object for construction of custom HTTP/2 CloseableHttpAsyncClient instances.
      • createHttp2MemoryBound

        public static org.apache.hc.client5.http.impl.async.CloseableHttpAsyncClient createHttp2MemoryBound()
        Creates HTTP/2 CloseableHttpAsyncClient instance that uses a memory bound response cache.
      • createHttp2FileBound

        public static org.apache.hc.client5.http.impl.async.CloseableHttpAsyncClient createHttp2FileBound​(java.io.File cacheDir)
        Creates HTTP/2 CloseableHttpAsyncClient instance that uses a file system bound response cache.
        Parameters:
        cacheDir - location of response cache.