[FIX] server: graceful shutdown must send SIGINT instead of SIGTERM to workers
Workers do not specifically handle SIGTERM so it can be used to force quit them, but the graceful shutdown is triggered by SIGINT. Closes #6738
This commit is contained in:
parent
e208fe51db
commit
d291aba4b5
|
@ -613,7 +613,7 @@ class PreforkServer(CommonServer):
|
|||
_logger.info("Stopping gracefully")
|
||||
limit = time.time() + self.timeout
|
||||
for pid in self.workers.keys():
|
||||
self.worker_kill(pid, signal.SIGTERM)
|
||||
self.worker_kill(pid, signal.SIGINT)
|
||||
while self.workers and time.time() < limit:
|
||||
self.process_zombie()
|
||||
time.sleep(0.1)
|
||||
|
|
Loading…
Reference in New Issue