mirror of
https://github.com/element-hq/matrix-authentication-service.git
synced 2026-08-29 01:08:41 +00:00
build(deps): bump sd-notify from 0.4.5 to 0.5.0 (#5796)
This commit is contained in:
Generated
+2
-2
@@ -5419,9 +5419,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "sd-notify"
|
||||
version = "0.4.5"
|
||||
version = "0.5.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b943eadf71d8b69e661330cb0e2656e31040acf21ee7708e2c238a0ec6af2bf4"
|
||||
checksum = "3e4ef7359e694bfaf1dd27a30f9d760b54c00dfae9f19bd0c05a39bc9128fe76"
|
||||
dependencies = [
|
||||
"libc",
|
||||
]
|
||||
|
||||
+1
-1
@@ -540,7 +540,7 @@ version = "1.13.0"
|
||||
|
||||
# systemd service status notification
|
||||
[workspace.dependencies.sd-notify]
|
||||
version = "0.4.5"
|
||||
version = "0.5.0"
|
||||
|
||||
# JSON Schema generation
|
||||
[workspace.dependencies.schemars]
|
||||
|
||||
@@ -64,7 +64,7 @@ impl Reloadable for Templates {
|
||||
|
||||
/// A wrapper around [`sd_notify::notify`] that logs any errors
|
||||
fn notify(states: &[sd_notify::NotifyState]) {
|
||||
if let Err(e) = sd_notify::notify(false, states) {
|
||||
if let Err(e) = sd_notify::notify(states) {
|
||||
tracing::error!(
|
||||
error = &e as &dyn std::error::Error,
|
||||
"Failed to notify service manager"
|
||||
@@ -133,16 +133,8 @@ impl LifecycleManager {
|
||||
notify(&[sd_notify::NotifyState::Ready]);
|
||||
|
||||
// This will be `Some` if we have the watchdog enabled, and `None` if not
|
||||
let mut watchdog_interval = {
|
||||
let mut watchdog_usec = 0;
|
||||
if sd_notify::watchdog_enabled(false, &mut watchdog_usec) {
|
||||
Some(tokio::time::interval(Duration::from_micros(
|
||||
watchdog_usec / 2,
|
||||
)))
|
||||
} else {
|
||||
None
|
||||
}
|
||||
};
|
||||
let mut watchdog_interval =
|
||||
sd_notify::watchdog_enabled().map(|timeout| tokio::time::interval(timeout / 2));
|
||||
|
||||
// Wait for a first shutdown signal and trigger the soft shutdown
|
||||
let likely_crashed = loop {
|
||||
|
||||
Reference in New Issue
Block a user