Skip to content

Instantly share code, notes, and snippets.

@DouweM
Created December 17, 2013 14:00
Show Gist options
  • Save DouweM/8005315 to your computer and use it in GitHub Desktop.
Save DouweM/8005315 to your computer and use it in GitHub Desktop.
queue_names = "aggregations,xml_generation,profile_generation,trip,billing,flume,end,snap,profile_analysis,etl,report_api,events,pipeline_entry,profile_aggregation,geocoder".split(",")
queues = {}
queue_names.each do |name|
queues[name] = []
end
Resque.working.each do |x|
name = x.job["queue"]
queue = queues[name]
next unless queue
queue << x.job["run_at"]
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment