Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix errors in graceful shutdown #912

Merged
merged 1 commit into from
Jan 11, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 10 additions & 6 deletions iris-mpc/src/bin/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -887,12 +887,16 @@ async fn server_main(config: Config) -> eyre::Result<()> {
.await
.expect("Deserialization of probe response failed");
if probe_response.shutting_down {
tracing::error!(
"Node {} has starting graceful shutdown. Therefore starting graceful \
shutdown",
host
);
heartbeat_shutdown_handler.trigger_manual_shutdown();
tracing::info!("Node {} has starting graceful shutdown", host);

if !heartbeat_shutdown_handler.is_shutting_down() {
heartbeat_shutdown_handler.trigger_manual_shutdown();
tracing::error!(
"Node {} has starting graceful shutdown, therefore triggering \
graceful shutdown",
host
);
}
}
if probe_response.image_name != image_name {
// Do not create a panic as we still can continue to process before its
Expand Down
Loading