pub struct RuntimeBuilder { /* private fields */ }Expand description
Builder for creating a runtime with custom configuration
Implementations§
Source§impl RuntimeBuilder
impl RuntimeBuilder
Sourcepub fn log_level(self, level: impl Into<String>) -> Self
pub fn log_level(self, level: impl Into<String>) -> Self
Set log level (trace, debug, info, warn, error)
Sourcepub fn log_format(self, format: LogFormat) -> Self
pub fn log_format(self, format: LogFormat) -> Self
Set log format
Sourcepub fn restart_policy(self, policy: RestartPolicy) -> Self
pub fn restart_policy(self, policy: RestartPolicy) -> Self
Set restart policy
Sourcepub fn health_check_interval(self, interval: Duration) -> Self
pub fn health_check_interval(self, interval: Duration) -> Self
Set health check interval
Sourcepub fn shutdown_timeout(self, timeout: Duration) -> Self
pub fn shutdown_timeout(self, timeout: Duration) -> Self
Set graceful shutdown timeout
Sourcepub fn with_launcher(self, enable: bool) -> Self
pub fn with_launcher(self, enable: bool) -> Self
Enable launcher service for dynamic node management
Sourcepub fn with_lifecycle(
self,
modes: HashMap<String, ModeConfig>,
default_mode: String,
) -> Self
pub fn with_lifecycle( self, modes: HashMap<String, ModeConfig>, default_mode: String, ) -> Self
Enable lifecycle management with mode configuration
§Arguments
modes- Map of mode name to mode configurationdefault_mode- Initial mode to start in
Trait Implementations§
Source§impl Default for RuntimeBuilder
impl Default for RuntimeBuilder
Source§fn default() -> RuntimeBuilder
fn default() -> RuntimeBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for RuntimeBuilder
impl RefUnwindSafe for RuntimeBuilder
impl Send for RuntimeBuilder
impl Sync for RuntimeBuilder
impl Unpin for RuntimeBuilder
impl UnwindSafe for RuntimeBuilder
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