[control] Fix round 4: a device change during an engine switch is never skipped silently (devices_problem until the serving engine is told), and every switch ends by telling the engine that serves, also after going back
This commit is contained in:
@@ -254,6 +254,17 @@ impl Control {
|
||||
});
|
||||
}
|
||||
}
|
||||
// Still under the engine lock: whichever engine serves now reads the device files again
|
||||
// (QC round 4). A device change during the switch only wrote them; a Caddy that was
|
||||
// already running, or started before they changed, would keep the old list.
|
||||
if self.pki.is_some()
|
||||
&& let Err(e) = self.nudge_devices().await
|
||||
{
|
||||
log::error!(target: "ianitor::engine", "after the switch: {e}; retrying");
|
||||
if let Ok(mut p) = self.devices_problem.lock() {
|
||||
*p = Some(e);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fn units_and_cfg(&self) -> Result<(Arc<dyn Units>, EngineConfig), String> {
|
||||
|
||||
Reference in New Issue
Block a user