pub struct StatsHandler { /* private fields */ }
Expand description
Stats handler for retrieving metrics
Implementations§
Source§impl StatsHandler
impl StatsHandler
pub fn new(client: RestClient) -> Self
Sourcepub async fn cluster(&self, query: Option<StatsQuery>) -> Result<StatsResponse>
pub async fn cluster(&self, query: Option<StatsQuery>) -> Result<StatsResponse>
Get cluster stats
Sourcepub async fn cluster_last(&self) -> Result<Value>
pub async fn cluster_last(&self) -> Result<Value>
Get cluster stats for last interval
Sourcepub async fn node(
&self,
uid: u32,
query: Option<StatsQuery>,
) -> Result<StatsResponse>
pub async fn node( &self, uid: u32, query: Option<StatsQuery>, ) -> Result<StatsResponse>
Get node stats
Sourcepub async fn database(
&self,
uid: u32,
query: Option<StatsQuery>,
) -> Result<StatsResponse>
pub async fn database( &self, uid: u32, query: Option<StatsQuery>, ) -> Result<StatsResponse>
Get database stats
Sourcepub async fn database_last(&self, uid: u32) -> Result<Value>
pub async fn database_last(&self, uid: u32) -> Result<Value>
Get database stats for last interval
Sourcepub async fn databases(&self, query: Option<StatsQuery>) -> Result<Value>
pub async fn databases(&self, query: Option<StatsQuery>) -> Result<Value>
Get all databases stats
Sourcepub async fn shard(
&self,
uid: u32,
query: Option<StatsQuery>,
) -> Result<StatsResponse>
pub async fn shard( &self, uid: u32, query: Option<StatsQuery>, ) -> Result<StatsResponse>
Get shard stats
Auto Trait Implementations§
impl Freeze for StatsHandler
impl !RefUnwindSafe for StatsHandler
impl Send for StatsHandler
impl Sync for StatsHandler
impl Unpin for StatsHandler
impl !UnwindSafe for StatsHandler
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more