pub struct PerformanceMonitor { /* private fields */ }Expand description
Performance monitoring service
Implementations§
Source§impl PerformanceMonitor
impl PerformanceMonitor
pub async fn new( config: MonitoringConfig, metrics_collector: Arc<MetricsCollector>, ) -> RragResult<Self>
pub async fn start(&self) -> RragResult<()>
pub async fn stop(&self) -> RragResult<()>
pub async fn is_healthy(&self) -> bool
pub async fn get_current_metrics(&self) -> RragResult<PerformanceMetrics>
pub async fn get_metrics_history(&self) -> Vec<PerformanceMetrics>
pub async fn get_average_metrics( &self, minutes: u32, ) -> RragResult<PerformanceMetrics>
Auto Trait Implementations§
impl !RefUnwindSafe for PerformanceMonitor
impl !UnwindSafe for PerformanceMonitor
impl Freeze for PerformanceMonitor
impl Send for PerformanceMonitor
impl Sync for PerformanceMonitor
impl Unpin for PerformanceMonitor
impl UnsafeUnpin for PerformanceMonitor
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