resque 1.16.1 → 1.17.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of resque might be problematic. Click here for more details.

data/HISTORY.md CHANGED
@@ -1,3 +1,11 @@
1
+ ## 1.17.0 (2011-05-26)
2
+
3
+ * Workers exit with `exit` instead of `exit!`. This means you
4
+ can now use `at_exit` hooks inside workers.
5
+ * More monit typo fixes.
6
+ * Fixed bug in Hoptoad backend.
7
+ * Web UI: Wrap preformatted arguments.
8
+
1
9
  ## 1.16.1 (2011-05-17)
2
10
 
3
11
  * Bugfix: Resque::Failure::Hoptoad.configure works again
@@ -23,9 +23,9 @@ module Resque
23
23
  # end
24
24
  # For more information see https://github.com/thoughtbot/hoptoad_notifier
25
25
  class Hoptoad < Base
26
- def self.configure
26
+ def self.configure(&block)
27
27
  Resque::Failure.backend = self
28
- HoptoadNotifier.configure
28
+ HoptoadNotifier.configure(&block)
29
29
  end
30
30
 
31
31
  def self.count
@@ -58,7 +58,7 @@ body { padding:0; margin:0; }
58
58
  #main table.stats th { font-size:100%; width:40%; color:#000;}
59
59
  #main hr { border:0; border-top:5px solid #efefef; margin:15px 0;}
60
60
 
61
- #footer { padding:10px 5%; background:#efefef; color:#999; font-size:85%; line-height:1.5; border-top:5px solid #ccc; padding-top:10px;}
61
+ #footer { padding:10px 5%; background:#efefef; color:#999; font-size:85%; line-height:1.5; border-top:5px solid #ccc; padding-top:10px;}
62
62
  #footer p a { color:#999;}
63
63
 
64
64
  #main p.poll { background:url(poll.png) no-repeat 0 2px; padding:3px 0; padding-left:23px; float:right; font-size:85%; }
@@ -72,7 +72,7 @@ body { padding:0; margin:0; }
72
72
  #main ul.failed li.hover dl dd .retried .remove { display:block; }
73
73
  #main ul.failed li dl dd .controls { display:none; float:right; }
74
74
  #main ul.failed li.hover dl dd .controls { display:block; }
75
- #main ul.failed li dl dd code, #main ul.failed li dl dd pre { font-family:Monaco, "Courier New", monospace; font-size:90%;}
75
+ #main ul.failed li dl dd code, #main ul.failed li dl dd pre { font-family:Monaco, "Courier New", monospace; font-size:90%; white-space: pre-wrap;}
76
76
  #main ul.failed li dl dd.error a {font-family:Monaco, "Courier New", monospace; font-size:90%; }
77
77
  #main ul.failed li dl dd.error pre { margin-top:3px; line-height:1.3;}
78
78
 
@@ -1,6 +1,7 @@
1
1
  <%start = params[:start].to_i %>
2
2
  <%failed = Resque::Failure.all(start, 20)%>
3
3
  <% index = 0 %>
4
+ <% date_format = "%Y/%m/%d %T %z" %>
4
5
 
5
6
  <h1>Failed Jobs</h1>
6
7
  <%unless failed.empty?%>
@@ -22,10 +23,10 @@
22
23
  <% else %>
23
24
  <dt>Worker</dt>
24
25
  <dd>
25
- <a href="<%= u(:workers, job['worker']) %>"><%= job['worker'].split(':')[0...2].join(':') %></a> on <b class='queue-tag'><%= job['queue'] %></b > at <b><span class="time"><%= Time.parse(job['failed_at']).strftime("%D %T %z") %></span></b>
26
+ <a href="<%= u(:workers, job['worker']) %>"><%= job['worker'].split(':')[0...2].join(':') %></a> on <b class='queue-tag'><%= job['queue'] %></b > at <b><span class="time"><%= Time.parse(job['failed_at']).strftime(date_format) %></span></b>
26
27
  <% if job['retried_at'] %>
27
28
  <div class='retried'>
28
- Retried <b><span class="time"><%= Time.parse(job['retried_at']).strftime("%D %T %z") %></span></b>
29
+ Retried <b><span class="time"><%= Time.parse(job['retried_at']).strftime(date_format) %></span></b>
29
30
  <a href="<%= u "failed/remove/#{start + index - 1}" %>" class="remove" rel="remove">Remove</a>
30
31
  </div>
31
32
  <% else %>
@@ -1,3 +1,3 @@
1
1
  module Resque
2
- Version = VERSION = '1.16.1'
2
+ Version = VERSION = '1.17.0'
3
3
  end
data/lib/resque/worker.rb CHANGED
@@ -128,7 +128,7 @@ module Resque
128
128
  else
129
129
  procline "Processing #{job.queue} since #{Time.now.to_i}"
130
130
  perform(job, &block)
131
- exit! unless @cant_fork
131
+ exit unless @cant_fork
132
132
  end
133
133
 
134
134
  done_working
@@ -302,7 +302,7 @@ module Resque
302
302
  def paused?
303
303
  @paused
304
304
  end
305
-
305
+
306
306
  # Stop processing jobs after the current one has completed (if we're
307
307
  # currently running one).
308
308
  def pause_processing
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: resque
3
3
  version: !ruby/object:Gem::Version
4
- hash: 85
4
+ hash: 83
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
- - 16
9
- - 1
10
- version: 1.16.1
8
+ - 17
9
+ - 0
10
+ version: 1.17.0
11
11
  platform: ruby
12
12
  authors:
13
13
  - Chris Wanstrath
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-05-17 00:00:00 -07:00
18
+ date: 2011-05-26 00:00:00 -07:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency