Trait Manager

Source
pub trait Manager: PlatformSync + Debug {
Show 20 methods // Required methods fn name(&self) -> &str; fn id(&self) -> Uuid; fn initialize<'life0, 'async_trait>( &'life0 mut self, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn shutdown<'life0, 'async_trait>( &'life0 mut self, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn status<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = ManagerStatus> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; // Provided methods fn health_check<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = HealthStatus> + Send + 'async_trait>> where Self: Sync + 'async_trait, 'life0: 'async_trait { ... } fn pause<'life0, 'async_trait>( &'life0 mut self, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: Send + 'async_trait, 'life0: 'async_trait { ... } fn resume<'life0, 'async_trait>( &'life0 mut self, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: Send + 'async_trait, 'life0: 'async_trait { ... } fn restart<'life0, 'async_trait>( &'life0 mut self, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: Send + 'async_trait, 'life0: 'async_trait { ... } fn get_config<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Option<Value>> + Send + 'async_trait>> where Self: Sync + 'async_trait, 'life0: 'async_trait { ... } fn update_config<'life0, 'async_trait>( &'life0 mut self, _config: Value, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: Send + 'async_trait, 'life0: 'async_trait { ... } fn dependencies(&self) -> Vec<String> { ... } fn priority(&self) -> i32 { ... } fn is_essential(&self) -> bool { ... } fn version(&self) -> Option<String> { ... } fn description(&self) -> Option<String> { ... } fn supports_runtime_reload(&self) -> bool { ... } fn reload_config<'life0, 'async_trait>( &'life0 mut self, _config: Value, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: Send + 'async_trait, 'life0: 'async_trait { ... } fn required_permissions(&self) -> Vec<String> { ... } fn platform_requirements(&self) -> PlatformRequirements { ... }
}
Expand description

Core trait for all system managers - conditional Send requirement based on target

Required Methods§

Source

fn name(&self) -> &str

Returns the manager name

Source

fn id(&self) -> Uuid

Returns the manager ID

Source

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

Initializes the manager

Source

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

Shuts down the manager

Source

fn status<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = ManagerStatus> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Returns current status

Provided Methods§

Source

fn health_check<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = HealthStatus> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Performs health check

Source

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

Pauses the manager

Source

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

Resumes the manager

Source

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

Restarts the manager

Source

fn get_config<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Option<Value>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Gets current configuration

Source

fn update_config<'life0, 'async_trait>( &'life0 mut self, _config: Value, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: Send + 'async_trait, 'life0: 'async_trait,

Updates configuration

Source

fn dependencies(&self) -> Vec<String>

Returns dependencies

Source

fn priority(&self) -> i32

Returns initialization priority

Source

fn is_essential(&self) -> bool

Checks if manager is essential for system operation

Source

fn version(&self) -> Option<String>

Returns manager version

Source

fn description(&self) -> Option<String>

Returns manager description

Source

fn supports_runtime_reload(&self) -> bool

Checks if manager supports runtime reloading

Source

fn reload_config<'life0, 'async_trait>( &'life0 mut self, _config: Value, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: Send + 'async_trait, 'life0: 'async_trait,

Reloads configuration at runtime

Source

fn required_permissions(&self) -> Vec<String>

Returns required permissions

Source

fn platform_requirements(&self) -> PlatformRequirements

Returns platform requirements

Implementors§