pub fn install_shutdown_handlers(watch_stdin: bool) -> CancellationTokenExpand description
Steps 8 & 9: spawn the stdin-watch thread (exit on EOF — matching Go’s stdinReadWatch) and the SIGINT/SIGTERM handler. Both cancel the returned token, which the WAL checkpoint loop and the final server select! also watch for graceful shutdown.