pub trait StorageMonitor: Send + Sync {
// Required methods
fn start_monitoring<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn stop_monitoring<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_metrics<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<HashMap<String, f64>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn set_alert_thresholds<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
thresholds: AlertThresholds,
) -> Pin<Box<dyn Future<Output = StorageResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_alerts<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<Vec<StorageAlert>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_usage_trends<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
period: TrendPeriod,
) -> Pin<Box<dyn Future<Output = StorageResult<UsageTrend>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn generate_report<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
report_type: ReportType,
) -> Pin<Box<dyn Future<Output = StorageResult<StorageReport>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}Expand description
Storage monitoring trait
Required Methods§
Sourcefn start_monitoring<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn start_monitoring<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Start monitoring storage operations
Sourcefn stop_monitoring<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn stop_monitoring<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Stop monitoring storage operations
Sourcefn get_metrics<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<HashMap<String, f64>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_metrics<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<HashMap<String, f64>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get real-time metrics
Sourcefn set_alert_thresholds<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
thresholds: AlertThresholds,
) -> Pin<Box<dyn Future<Output = StorageResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn set_alert_thresholds<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
thresholds: AlertThresholds,
) -> Pin<Box<dyn Future<Output = StorageResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Set alert thresholds
Sourcefn get_alerts<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<Vec<StorageAlert>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_alerts<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = StorageResult<Vec<StorageAlert>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get current alerts
Sourcefn get_usage_trends<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
period: TrendPeriod,
) -> Pin<Box<dyn Future<Output = StorageResult<UsageTrend>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_usage_trends<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
period: TrendPeriod,
) -> Pin<Box<dyn Future<Output = StorageResult<UsageTrend>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get usage trends
Sourcefn generate_report<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
report_type: ReportType,
) -> Pin<Box<dyn Future<Output = StorageResult<StorageReport>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn generate_report<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket_name: &'life1 str,
report_type: ReportType,
) -> Pin<Box<dyn Future<Output = StorageResult<StorageReport>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Generate storage report
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".