Skip to content

Commit

Permalink
Abort gateway in case of SPDK ping failure.
Browse files Browse the repository at this point in the history
Fixes #914

Signed-off-by: Gil Bregman <gbregman@il.ibm.com>
  • Loading branch information
gbregman committed Oct 27, 2024
1 parent 76aed58 commit f72e3cd
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion control/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -687,7 +687,9 @@ def keep_alive(self):
consecutive_ping_failures += 1
if consecutive_ping_failures >= allowed_consecutive_spdk_ping_failures:
self.logger.critical(f"SPDK ping failed {consecutive_ping_failures} times, aborting")
break
raise SystemExit(f"SPDK ping failed, quitting gateway")
else:
self.logger.warning(f"SPDK ping failed {consecutive_ping_failures} times, will keep trying")
else:
consecutive_ping_failures = 0

Expand Down

0 comments on commit f72e3cd

Please sign in to comment.