common_meta::cluster

Trait ClusterInfo

source
pub trait ClusterInfo {
    type Error: ErrorExt;

    // Required methods
    fn list_nodes<'life0, 'async_trait>(
        &'life0 self,
        role: Option<Role>,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<NodeInfo>, Self::Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn list_region_stats<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<RegionStat>, Self::Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

ClusterInfo provides information about the cluster.

Required Associated Types§

source

type Error: ErrorExt

Required Methods§

source

fn list_nodes<'life0, 'async_trait>( &'life0 self, role: Option<Role>, ) -> Pin<Box<dyn Future<Output = Result<Vec<NodeInfo>, Self::Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

List all nodes by role in the cluster. If role is None, list all nodes.

source

fn list_region_stats<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Vec<RegionStat>, Self::Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

List all region stats in the cluster.

Implementors§