Interface RequestOptions


public interface RequestOptions
Interface used to specify options for making HTTP requests.
  • Method Details

    • withHttpMode

      RequestOptions withHttpMode(HttpMode httpMode)
      Specify HTTP mode to be used when request sent.
      Parameters:
      httpMode - An HttpMode enum value which indicates how a request should be sent.
      Returns:
      request options
    • withConnectionId

      RequestOptions withConnectionId(String connectionId)
      Specify connectionId when sending request over specific connection.
      Parameters:
      connectionId - The connection identifier to use.
      Returns:
      request options
    • withUpstreamTLSVerification

      RequestOptions withUpstreamTLSVerification()
      Enforce upstream TLS verification when request sent.
      Returns:
      request options
    • withRedirectionMode

      RequestOptions withRedirectionMode(RedirectionMode redirectionMode)
      Specify redirection mode to be used when request sent.
      Parameters:
      redirectionMode - A RedirectionMode enum value which indicates how redirects should be handled.
      Returns:
      request options
    • withServerNameIndicator

      RequestOptions withServerNameIndicator(String serverNameIndicator)
      Specify the server name indicator (SNI) to be used when request sent.
      Parameters:
      serverNameIndicator - The server name indicator to use.
      Returns:
      request options
    • withResponseTimeout

      RequestOptions withResponseTimeout(long timeoutMs)
      Specify the timeout to be used while reading the response.
      Parameters:
      timeoutMs - timeout in ms. Zero indicates no timeout.
      Returns:
      request options
    • requestOptions

      static RequestOptions requestOptions()
      Use to obtain a new RequestOptions instance
      Returns:
      request options