Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

RQ "leaks" worker registrations #55

Closed
nvie opened this Issue · 8 comments

5 participants

@nvie
Owner

Workers cannot be unregistered upon cold shut down, since there is no hook for that, UNIX-wise. Therefore, worker keys in Redis won't be cleaned up.

Affected keys:

  • rq:worker:<uuid>
  • rq:workers (set members)

This bug is even more annoying due to #48.

@nvie
Owner

The most reliable approach to solving this problem is to put Redis timeouts on the worker keys.

@passy

+1 on timeouts. I was confused when I took a look at rqinfo after a few restarts and saw a couple of dozen workers hanging around where I expected only one to be active.

@armonge

This also affects when running under supervisor, with a configuration like the following rq fails to restart without manually deleting some keys

[program:rq]
command=rqworker -v --name=myrq
process_name=%(program_name)s
directory=/my/path
autostart=true
autorestart=true
stdout-logfile=/my/path/logs/rq.log
stderr_logfile=/my/path/logs/rq.log
@nvie
Owner

Fixed in 0.3.0.

@selwin
Collaborator

@nvie since this is fixed in 0.3.0, this issue should probably be closed

@nvie
Owner

Fixed in 0.3.0.

@nvie nvie closed this
@drewyeaton

I realize this issue is fixed currently, but what's the best way to clean up these leaked worker registrations?

@nvie
Owner
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.