lib/backburner/allq_wrapper.rb in backburner-allq-1.0.38 vs lib/backburner/allq_wrapper.rb in backburner-allq-1.0.39
- old
+ new
@@ -80,10 +80,14 @@
end
def stats
{ 'expireds' => expireds, 'releases' => releases }
end
+
+ def clear(tube)
+ @client.clear(tube)
+ end
end
class AllQWrapper
DEFAULT_TIMEOUT = 17_800
def initialize(url = 'localhost:8090')
@@ -93,9 +97,13 @@
raw_client = Allq::ApiClient.new(allq_conf)
@client = Allq::ActionsApi.new(raw_client)
@admin = Allq::AdminApi.new(raw_client)
@recent_times = []
+ end
+
+ def clear(tube)
+ @client.tube_delete(tube)
end
def touch(job)
@client.touch_put(job.id)
end