c

wvlet.airframe.http.client

HttpClientConfig

case class HttpClientConfig(name: String = "default", backend: HttpClientBackend = Compat.defaultHttpClientBackend, requestFilter: (Request) => Request = identity, responseFilter: (Response) => Response = identity, rpcEncoding: RPCEncoding = RPCEncoding.JSON, retryContext: RetryContext = Compat.defaultHttpClientBackend.defaultRequestRetryer, codecFactory: MessageCodecFactory = MessageCodecFactory.defaultFactoryForJSON, circuitBreaker: CircuitBreaker = CircuitBreaker.withConsecutiveFailures(5), connectTimeout: Duration = Duration(90, TimeUnit.SECONDS), readTimeout: Duration = Duration(90, TimeUnit.SECONDS), clientFilter: HttpClientFilter = HttpClientFilter.identity, httpLoggerConfig: HttpLoggerConfig = HttpLoggerConfig(logFileName = "log/http_client.json"), httpLoggerProvider: (HttpLoggerConfig) => HttpLogger = Compat.defaultHttpClientLoggerFactory, loggingFilter: (HttpLogger) => HttpClientFilter = (l: HttpLogger) => new HttpClientLoggingFilter(l)) extends HttpChannelConfig with Product with Serializable

Linear Supertypes
Serializable, Product, Equals, HttpChannelConfig, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. HttpClientConfig
  2. Serializable
  3. Product
  4. Equals
  5. HttpChannelConfig
  6. AnyRef
  7. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new HttpClientConfig(name: String = "default", backend: HttpClientBackend = Compat.defaultHttpClientBackend, requestFilter: (Request) => Request = identity, responseFilter: (Response) => Response = identity, rpcEncoding: RPCEncoding = RPCEncoding.JSON, retryContext: RetryContext = Compat.defaultHttpClientBackend.defaultRequestRetryer, codecFactory: MessageCodecFactory = MessageCodecFactory.defaultFactoryForJSON, circuitBreaker: CircuitBreaker = CircuitBreaker.withConsecutiveFailures(5), connectTimeout: Duration = Duration(90, TimeUnit.SECONDS), readTimeout: Duration = Duration(90, TimeUnit.SECONDS), clientFilter: HttpClientFilter = HttpClientFilter.identity, httpLoggerConfig: HttpLoggerConfig = HttpLoggerConfig(logFileName = "log/http_client.json"), httpLoggerProvider: (HttpLoggerConfig) => HttpLogger = Compat.defaultHttpClientLoggerFactory, loggingFilter: (HttpLogger) => HttpClientFilter = (l: HttpLogger) => new HttpClientLoggingFilter(l))

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. val backend: HttpClientBackend
  6. val circuitBreaker: CircuitBreaker
  7. val clientFilter: HttpClientFilter
  8. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
  9. val codecFactory: MessageCodecFactory
  10. val connectTimeout: Duration
    Definition Classes
    HttpClientConfigHttpChannelConfig
  11. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  12. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  13. val httpLoggerConfig: HttpLoggerConfig
  14. val httpLoggerProvider: (HttpLoggerConfig) => HttpLogger
  15. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  16. val loggingFilter: (HttpLogger) => HttpClientFilter
  17. val name: String
  18. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  19. def newAsyncClient(serverAddress: String): AsyncClient
  20. def newHttpLogger: HttpLogger
  21. def newJSClient: AsyncClient

    Create a default Async client for Scala.js in web browsers

  22. def newLoggingFilter(logger: HttpLogger): HttpClientFilter
  23. def newSyncClient(serverAddress: String): SyncClient
  24. def noCircuitBreaker: HttpClientConfig
  25. def noClientFilter: HttpClientConfig

    Remove any client-side filter

  26. def noLogging: HttpClientConfig

    Disable http-client side logging

  27. def noRequestFilter: HttpClientConfig
  28. def noResponseFilter: HttpClientConfig
  29. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  30. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  31. def productElementNames: Iterator[String]
    Definition Classes
    Product
  32. val readTimeout: Duration
    Definition Classes
    HttpClientConfigHttpChannelConfig
  33. val requestFilter: (Request) => Request
  34. val responseFilter: (Response) => Response
  35. val retryContext: RetryContext
  36. val rpcEncoding: RPCEncoding
  37. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  38. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  39. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  40. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  41. def withBackend(newBackend: HttpClientBackend): HttpClientConfig
  42. def withCircuitBreaker(f: (CircuitBreaker) => CircuitBreaker): HttpClientConfig
  43. def withClientFilter(filter: RxHttpFilter): HttpClientConfig

    Add a new RxClientFilter.

    Add a new RxClientFilter. This filter is useful for adding a common error handling logic for the Rx[Response].

  44. def withClientFilter(filter: HttpClientFilter): HttpClientConfig

    Add a new HttpClientFilter.

    Add a new HttpClientFilter. This filter is useful for adding a common error handling logic for the Rx[Response].

  45. def withCodecFactory(newCodecFactory: MessageCodecFactory): HttpClientConfig
  46. def withConnectTimeout(duration: Duration): HttpClientConfig
  47. def withDebugConsoleLogger: HttpClientConfig

    Use Debug Console http logging

  48. def withHttpLogger(loggerProvider: (HttpLoggerConfig) => HttpLogger): HttpClientConfig
  49. def withJSONEncoding: HttpClientConfig
  50. def withLoggerConfig(f: (HttpLoggerConfig) => HttpLoggerConfig): HttpClientConfig

    Customize logger configuration

  51. def withMsgPackEncoding: HttpClientConfig
  52. def withName(name: String): HttpClientConfig
  53. def withRPCEncoding(newEncoding: RPCEncoding): HttpClientConfig
  54. def withReadTimeout(duration: Duration): HttpClientConfig
  55. def withRequestFilter(newRequestFilter: (Request) => Request): HttpClientConfig

    Add a custom request filter, e.g., for adding Authentication headers

  56. def withResponseFilter(newResponseFilter: (Response) => Response): HttpClientConfig

    Add a custom response filter, mostly for debugging purpose

  57. def withRetryContext(filter: (RetryContext) => RetryContext): HttpClientConfig

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated @Deprecated
    Deprecated

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from HttpChannelConfig

Inherited from AnyRef

Inherited from Any

Ungrouped