resque / resque/resque-scheduler
Cleaning up the scheduled jobs
Nobody has claimed this yet.
- Dominant language
- Ruby
- Stars
- 1.7k
- Forks
- 477
- PR merge metrics
- No merged PRs in 30d
Description
Hello all -
I have a question regarding how the scheduled jobs are clean up from redis. I was looking at this code: https://github.com/resque/resque-scheduler/blob/6e86834e9ff35fb9e976ab79176b650f19385562/lib/resque/scheduler/delaying_extensions.rb#L114
I'm seeing some huge discrepancies in redis between the size of resque:delayed_queue_schedule and the amount of "resque:delayed:1419022315" and "resque:timestamps:.." .
I was thinking if it possible that some jobs didn't get clean properly. What happens if an exception is thrown in this part of the code?
Is there a way to clean up timestamps that are older than x ?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with lib/resque/scheduler/delaying_extensions.rb around line 114 and inspect how scheduled jobs and timestamps are removed from Redis, including exception handling. Compare resque:delayed_queue_schedule with the resque:delayed:* and resque:timestamps:* keys described in the issue. Done would require an agreed cleanup behavior for stale timestamps and a clear way to verify it.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- redis, ruby
- Domain
- backend, databases
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100