Revert "Ensure all Sidekiq queues are always alive"
This reverts commit bba787c06e
.
This commit is contained in:
parent
bba787c06e
commit
f2ea3d1c98
12
mastodon.nix
12
mastodon.nix
@ -36,7 +36,6 @@ let
|
||||
sidekiq-manager = pkgs.writers.writePython3 "sidekiq-manager" {} ''
|
||||
from itertools import permutations
|
||||
from subprocess import Popen
|
||||
from time import sleep
|
||||
|
||||
|
||||
def sidekiq(queues, connections=16):
|
||||
@ -53,17 +52,6 @@ let
|
||||
queues = ['default', 'push', 'ingress']
|
||||
procs += [sidekiq(qs) for qs in permutations(queues)]
|
||||
|
||||
for p in procs:
|
||||
sleep(1)
|
||||
if p.poll():
|
||||
# one of the queues is dead
|
||||
break
|
||||
|
||||
# terminate the rest queues
|
||||
for p in procs:
|
||||
# https://github.com/sidekiq/sidekiq/wiki/Signals#term
|
||||
p.terminate()
|
||||
|
||||
for p in procs:
|
||||
p.wait()
|
||||
'';
|
||||
|
Loading…
Reference in New Issue
Block a user