pub struct SupervisionSettings {
pub restart_mode: RestartMode,
pub restart_intensity: usize,
pub restart_period_ms: u64,
pub auto_shutdown: AutoShutdown,
pub shutdown_budget_ms: Option<u64>,
pub dedicated_threads: Option<usize>,
pub restarts_performed: u64,
pub generation: u64,
}Expand description
How a supervisor supervises its children, and how it has fared.
Fields§
§restart_mode: RestartModeWhether a failing child is restarted alone or together with its siblings.
restart_intensity: usizeHow many restarts the supervisor tolerates within restart_period_ms before giving up.
restart_period_ms: u64The window over which restart_intensity is measured, in milliseconds.
auto_shutdown: AutoShutdownWhether the termination of a significant child drives the supervisor to shut down.
shutdown_budget_ms: Option<u64>How long the supervisor allows its children to drain during shutdown, in milliseconds. None if unbounded.
dedicated_threads: Option<usize>Worker threads on the supervisor’s own runtime. None if it runs on its parent’s runtime.
restarts_performed: u64How many child restarts the supervisor has performed, across all of its own generations.
A group restart counts once here however many children it brought back, which is what distinguishes a supervisor restarting its whole group repeatedly from a single child restarting repeatedly.
generation: u64How many times the supervisor has started running.
Trait Implementations§
Source§impl Clone for SupervisionSettings
impl Clone for SupervisionSettings
Source§fn clone(&self) -> SupervisionSettings
fn clone(&self) -> SupervisionSettings
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for SupervisionSettings
impl Debug for SupervisionSettings
Source§impl<'de> Deserialize<'de> for SupervisionSettings
impl<'de> Deserialize<'de> for SupervisionSettings
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Serialize for SupervisionSettings
impl Serialize for SupervisionSettings
impl Copy for SupervisionSettings
Auto Trait Implementations§
impl Freeze for SupervisionSettings
impl RefUnwindSafe for SupervisionSettings
impl Send for SupervisionSettings
impl Sync for SupervisionSettings
impl Unpin for SupervisionSettings
impl UnwindSafe for SupervisionSettings
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::RequestSource§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> Track for T
impl<T> Track for T
§fn track_resources(self, token: ResourceGroupToken) -> Tracked<Self>
fn track_resources(self, token: ResourceGroupToken) -> Tracked<Self>
Tracked wrapper. Read more§fn in_current_resource_group(self) -> Tracked<Self>
fn in_current_resource_group(self) -> Tracked<Self>
Tracked wrapper. Read more