[−][src]Struct elasticsearch::http::transport::Transport
A HTTP transport responsible for making the API requests to Elasticsearch, using a Connection selected from a ConnectionPool
Methods
impl Transport
[src]
pub fn single_node(url: &str) -> Result<Transport, Error>
[src]
Creates a new instance of a Transport configured with a SingleNodeConnectionPool.
pub fn cloud(
cloud_id: &str,
credentials: Credentials
) -> Result<Transport, Error>
[src]
cloud_id: &str,
credentials: Credentials
) -> Result<Transport, Error>
Creates a new instance of a Transport configured for use with Elasticsearch service in Elastic Cloud.
cloud_id
: The Elastic Cloud Id retrieved from the cloud web console, that uniquely identifies the deployment instance.credentials
: A set of credentials the client should use to authenticate to Elasticsearch service.
pub async fn send<'_, '_, '_, B, Q: ?Sized>(
&'_ self,
method: Method,
path: &'_ str,
headers: HeaderMap,
query_string: Option<&'_ Q>,
body: Option<B>
) -> Result<Response, Error> where
B: Body,
Q: Serialize,
[src]
&'_ self,
method: Method,
path: &'_ str,
headers: HeaderMap,
query_string: Option<&'_ Q>,
body: Option<B>
) -> Result<Response, Error> where
B: Body,
Q: Serialize,
Creates an asynchronous request that can be awaited
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Transport
impl Send for Transport
impl Sync for Transport
impl Unpin for Transport
impl !UnwindSafe for Transport
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DynClone for T where
T: Clone,
[src]
T: Clone,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,