pub struct TransportBuilder { /* private fields */ }
Expand description

Builds a HTTP transport to make API calls to Elasticsearch

Implementations

Creates a new instance of TransportBuilder. Accepts a ConnectionPool from which Connections to Elasticsearch will be retrieved.

Configures a proxy.

An optional username and password will be used to set the Proxy-Authorization header using Basic Authentication.

Whether to disable proxies, including system proxies.

NOTE: System proxies are enabled by default.

Credentials for the client to use for authentication to Elasticsearch

Validation applied to the certificate provided to establish a HTTPS connection. By default, full validation is applied. When using a self-signed certificate, different validation can be applied.

Adds a HTTP header that will be added to all client API calls.

A default HTTP header can be overridden on a per API call basis.

Adds HTTP headers that will be added to all client API calls.

Default HTTP headers can be overridden on a per API call basis.

Whether to send a x-elastic-client-meta header that describes the runtime environment.

This header contains information that is similar to what could be found in User-Agent. Using a separate header allows applications to use User-Agent for their own needs, e.g. to identify application version or other environment information. Defaults to true.

Sets a global request timeout for the client.

The timeout is applied from when the request starts connecting until the response body has finished. Default is no timeout.

Builds a Transport to use to send API calls to Elasticsearch.

Trait Implementations

Creates a default implementation using the default implementation of SingleNodeConnectionPool.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more