mirror of
https://github.com/xcat2/confluent.git
synced 2026-09-02 15:36:05 +00:00
78048d01a1
A member of a collective that cannot reach quorum stalls in the startup loop until quorum returns, and there was nothing in that loop that noticed a shutdown. That was survivable while SIGTERM raised SystemExit out of the signal handler, since that escaped the loop from wherever it happened to be. Having the event loop deliver the signal instead leaves the stop event set with nobody reading it until quorum is reached, so stopping the service waits out the systemd timeout and ends in a kill. Check the event in the loop condition, and wait on it rather than sleeping through it, so the answer comes in milliseconds rather than whenever quorum returns. A service stopped at this point has served nothing yet, so it goes straight to the same configuration flush the normal exit does.