Struct async_consul::Catalog[][src]

pub struct Catalog { /* fields omitted */ }

Catalog operations.

This type can be used to interact with the "Catalog" portion of the Consul API.

Implementations

impl Catalog[src]

pub async fn get_service_nodes(
    &self,
    service: &str,
    options: Option<QueryOptions>
) -> Result<(Vec<CatalogServiceNode>, QueryMetadata), Error>
[src]

Gets the nodes running the specified service.

pub fn watch_service_nodes(
    &self,
    service: &str,
    options: Option<QueryOptions>
) -> impl Stream<Item = Result<(Vec<CatalogServiceNode>, QueryMetadata), Error>>
[src]

Gets a stream of changes in nodes running the specified service.

Each item in the response stream represents all nodes running in the service after a change to the service has occurred. The stream will terminate if any error is hit during the background requests made to Consul.

Trait Implementations

impl Clone for Catalog[src]

impl Debug for Catalog[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,