Class InternalHttpClient

java.lang.Object
org.apache.hc.client5.http.impl.classic.CloseableHttpClient
org.apache.hc.client5.http.impl.classic.InternalHttpClient
All Implemented Interfaces:
Closeable, AutoCloseable, HttpClient, Configurable, org.apache.hc.core5.io.ModalCloseable

@Contract(threading=SAFE_CONDITIONAL) @Internal class InternalHttpClient extends CloseableHttpClient implements Configurable
Internal implementation of CloseableHttpClient.

Concurrent message exchanges executed by this client will get assigned to separate connections leased from the connection pool.

Since:
4.3
  • Field Details

  • Constructor Details

  • Method Details

    • determineRoute

      private HttpRoute determineRoute(org.apache.hc.core5.http.HttpHost target, org.apache.hc.core5.http.HttpRequest request, org.apache.hc.core5.http.protocol.HttpContext context) throws org.apache.hc.core5.http.HttpException
      Throws:
      org.apache.hc.core5.http.HttpException
    • setupContext

      private void setupContext(HttpClientContext context)
    • doExecute

      protected CloseableHttpResponse doExecute(org.apache.hc.core5.http.HttpHost target, org.apache.hc.core5.http.ClassicHttpRequest request, org.apache.hc.core5.http.protocol.HttpContext context) throws IOException
      Specified by:
      doExecute in class CloseableHttpClient
      Throws:
      IOException
    • getConfig

      public RequestConfig getConfig()
      Description copied from interface: Configurable
      Gets the actual request configuration.
      Specified by:
      getConfig in interface Configurable
      Returns:
      the actual request configuration.
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable
    • close

      public void close(org.apache.hc.core5.io.CloseMode closeMode)
      Specified by:
      close in interface org.apache.hc.core5.io.ModalCloseable