pub struct AutoTuner { /* private fields */ }Expand description
Automatic network configuration tuner
Implementations§
Source§impl AutoTuner
impl AutoTuner
Sourcepub fn with_config(config: AutoTunerConfig) -> Self
pub fn with_config(config: AutoTunerConfig) -> Self
Create a new auto-tuner with custom configuration
Sourcepub async fn analyze_system(
&mut self,
) -> Result<SystemResources, AutoTunerError>
pub async fn analyze_system( &mut self, ) -> Result<SystemResources, AutoTunerError>
Analyze system resources
Sourcepub async fn generate_config(&mut self) -> Result<NetworkConfig, AutoTunerError>
pub async fn generate_config(&mut self) -> Result<NetworkConfig, AutoTunerError>
Generate optimized network configuration based on detected resources
Sourcepub fn update_workload(
&mut self,
connections: usize,
query_rate: f64,
bandwidth_usage: f64,
memory_usage: u64,
)
pub fn update_workload( &mut self, connections: usize, query_rate: f64, bandwidth_usage: f64, memory_usage: u64, )
Update workload profile based on observed metrics
Sourcepub async fn start_monitoring(&mut self) -> Result<(), AutoTunerError>
pub async fn start_monitoring(&mut self) -> Result<(), AutoTunerError>
Start continuous monitoring and auto-adjustment
Sourcepub fn stop_monitoring(&mut self)
pub fn stop_monitoring(&mut self)
Stop continuous monitoring
Sourcepub fn is_monitoring(&self) -> bool
pub fn is_monitoring(&self) -> bool
Check if monitoring is active
Sourcepub fn workload_profile(&self) -> &WorkloadProfile
pub fn workload_profile(&self) -> &WorkloadProfile
Get current workload profile
Sourcepub fn stats(&self) -> AutoTunerStats
pub fn stats(&self) -> AutoTunerStats
Get current statistics
Sourcepub fn recommendations(&self) -> Vec<String>
pub fn recommendations(&self) -> Vec<String>
Generate recommendations for manual tuning
Trait Implementations§
Auto Trait Implementations§
impl Freeze for AutoTuner
impl !RefUnwindSafe for AutoTuner
impl Send for AutoTuner
impl Sync for AutoTuner
impl Unpin for AutoTuner
impl !UnwindSafe for AutoTuner
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more