Package com.azure.core.http.vertx
Class VertxAsyncHttpClientBuilder
java.lang.Object
com.azure.core.http.vertx.VertxAsyncHttpClientBuilder
Builds a
VertxAsyncHttpClient
.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Creates a new Vert.xHttpClient
instance on every call, using the configuration set in the builder at the time of the build method call.configuration
(Configuration configuration) Sets the configuration store that is used during construction of the HTTP client.connectTimeout
(Duration connectTimeout) Sets the connect timeout.httpClientOptions
(io.vertx.core.http.HttpClientOptions httpClientOptions) Sets customHttpClientOptions
for the constructedHttpClient
.idleTimeout
(Duration idleTimeout) Sets the connection idle timeout.proxy
(ProxyOptions proxyOptions) Sets proxy configuration.readIdleTimeout
(Duration readIdleTimeout) Sets the read idle timeout.vertx
(io.vertx.core.Vertx vertx) Sets a customVertx
instance that the constructedHttpClient
will be created with.writeIdleTimeout
(Duration writeIdleTimeout) Sets the write idle timeout.
-
Constructor Details
-
VertxAsyncHttpClientBuilder
public VertxAsyncHttpClientBuilder()
-
-
Method Details
-
readIdleTimeout
Sets the read idle timeout. The default read idle timeout is 60 seconds.- Parameters:
readIdleTimeout
- the read idle timeout- Returns:
- the updated VertxAsyncHttpClientBuilder object
-
writeIdleTimeout
Sets the write idle timeout. The default read idle timeout is 60 seconds.- Parameters:
writeIdleTimeout
- the write idle timeout- Returns:
- the updated VertxAsyncHttpClientBuilder object
-
connectTimeout
Sets the connect timeout. The default connect timeout is 10 seconds.- Parameters:
connectTimeout
- the connection timeout- Returns:
- the updated VertxAsyncHttpClientBuilder object
-
idleTimeout
Sets the connection idle timeout. The default connect timeout is 60 seconds.- Parameters:
idleTimeout
- the connection idle timeout- Returns:
- the updated VertxAsyncHttpClientBuilder object
-
proxy
Sets proxy configuration.- Parameters:
proxyOptions
- The proxy configuration to use.- Returns:
- The updated VertxAsyncHttpClientBuilder object.
-
configuration
Sets the configuration store that is used during construction of the HTTP client.The default configuration store is a clone of the
global configuration store
, useConfiguration.NONE
to bypass using configuration settings during construction.- Parameters:
configuration
- The configuration store.- Returns:
- The updated VertxAsyncHttpClientBuilder object.
-
httpClientOptions
public VertxAsyncHttpClientBuilder httpClientOptions(io.vertx.core.http.HttpClientOptions httpClientOptions) Sets customHttpClientOptions
for the constructedHttpClient
.- Parameters:
httpClientOptions
- The options of the web client.- Returns:
- The updated VertxAsyncHttpClientBuilder object
-
vertx
Sets a customVertx
instance that the constructedHttpClient
will be created with.- Parameters:
vertx
- The vertx instance.- Returns:
- The updated VertxAsyncHttpClientBuilder object
-
build
Creates a new Vert.xHttpClient
instance on every call, using the configuration set in the builder at the time of the build method call.- Returns:
- A new Vert.x backed
HttpClient
instance.
-