em-beanstalk 0.0.9 → 0.0.10

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.9
1
+ 0.0.10
data/lib/em-beanstalk.rb CHANGED
@@ -179,6 +179,8 @@ module EM
179
179
 
180
180
  def release(val, opts = nil, &block)
181
181
  return if val.nil?
182
+ delay = opts && opts[:delay] || default_delay
183
+ priority = opts && opts[:priority] || default_priority
182
184
  @conn.send(:release, job_id(val), priority.to_i, delay.to_i)
183
185
  add_deferrable(&block)
184
186
  end
@@ -20,6 +20,10 @@ module EM
20
20
  conn.delete(self, &block)
21
21
  end
22
22
 
23
+ def release(delay = 0, &block)
24
+ conn.release(self, :delay => delay, :priority => priority, &block)
25
+ end
26
+
23
27
  def stats(&block)
24
28
  conn.stats(:job, self, &block)
25
29
  end
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 9
9
- version: 0.0.9
8
+ - 10
9
+ version: 0.0.10
10
10
  platform: ruby
11
11
  authors:
12
12
  - Dan