AsyncHttpClient
object AsyncHttpClient
class Object
trait Matchable
class Any
Value members
Concrete methods
def allocate[F[_]](config: AsyncHttpClientConfig)(implicit F: ConcurrentEffect[F]): F[(Client[F], F[Unit])]
Allocates a Client and its shutdown mechanism for freeing resources.
Allocates a Client and its shutdown mechanism for freeing resources.
Create a custom AsyncHttpClientConfig
Create a custom AsyncHttpClientConfig
- Value Params
- configurationFn
function that maps from the builder of the defaultConfig to the custom config's builder
- Returns
a custom configuration.
def resource[F[_]](config: AsyncHttpClientConfig)(implicit F: ConcurrentEffect[F]): Resource[F, Client[F]]
Create an HTTP client based on the AsyncHttpClient library
Create an HTTP client based on the AsyncHttpClient library
- Value Params
- config
configuration for the client
def stream[F[_]](config: AsyncHttpClientConfig)(implicit F: ConcurrentEffect[F]): Stream[F, Client[F]]
Create a bracketed HTTP client based on the AsyncHttpClient library.
Create a bracketed HTTP client based on the AsyncHttpClient library.
- Value Params
- config
configuration for the client
- Returns
a singleton stream of the client. The client will be shutdown when the stream terminates.