pub struct ReloadCoordinator { /* private fields */ }Expand description
Runs reloads, one at a time.
Implementations§
Source§impl ReloadCoordinator
impl ReloadCoordinator
Sourcepub fn new(dir: impl Into<PathBuf>) -> Self
pub fn new(dir: impl Into<PathBuf>) -> Self
dir holds the marker (the host’s runtime directory).
Sourcepub fn ready_timeout(self, timeout: Duration) -> Self
pub fn ready_timeout(self, timeout: Duration) -> Self
How long the replacement gets to become ready. Default 30 s.
pub fn dir(&self) -> &Path
Sourcepub fn run(
&self,
host: &dyn ReloadHost,
request: &ReloadRequest,
staged: Option<&StagedBinary>,
) -> Result<(), ReloadError>
pub fn run( &self, host: &dyn ReloadHost, request: &ReloadRequest, staged: Option<&StagedBinary>, ) -> Result<(), ReloadError>
Run the saga. Ok only when the replacement answered ready and the host resumed.
Auto Trait Implementations§
impl !Freeze for ReloadCoordinator
impl RefUnwindSafe for ReloadCoordinator
impl Send for ReloadCoordinator
impl Sync for ReloadCoordinator
impl Unpin for ReloadCoordinator
impl UnsafeUnpin for ReloadCoordinator
impl UnwindSafe for ReloadCoordinator
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