pub async fn run_with_shutdown<F, Fut>(run: F) -> Result<()>Expand description
Runs a service future until it completes or a shutdown signal is received.
On SIGTERM or Ctrl-C, the provided root cancellation token is cancelled and the service future
is given GRACE_PERIOD to complete. If it does not, the process exits immediately so
blocking work cannot hold the Tokio runtime alive indefinitely.