pub trait HealthCheck: Send + Sync {
// Required methods
fn check<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = DMSCResult<DMSCHealthCheckResult>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn name(&self) -> &str;
fn config(&self) -> &DMSCHealthCheckConfig;
}Expand description
Trait for implementing custom health checks.
Required Methods§
Sourcefn check<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = DMSCResult<DMSCHealthCheckResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn check<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = DMSCResult<DMSCHealthCheckResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Performs the health check and returns the result.
Sourcefn config(&self) -> &DMSCHealthCheckConfig
fn config(&self) -> &DMSCHealthCheckConfig
Returns the configuration for this health check.