sidekiq 3.0.2 → 3.1.0
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of sidekiq might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/.travis.yml +1 -1
- data/Changes.md +23 -0
- data/Pro-Changes.md +8 -0
- data/lib/sidekiq/api.rb +77 -13
- data/lib/sidekiq/cli.rb +14 -17
- data/lib/sidekiq/logging.rb +1 -1
- data/lib/sidekiq/manager.rb +4 -1
- data/lib/sidekiq/processor.rb +0 -3
- data/lib/sidekiq/rails.rb +15 -0
- data/lib/sidekiq/util.rb +11 -0
- data/lib/sidekiq/version.rb +1 -1
- data/lib/sidekiq/web.rb +39 -42
- data/sidekiq.gemspec +2 -2
- data/test/helper.rb +1 -1
- data/test/test_api.rb +24 -4
- data/test/test_cli.rb +16 -16
- data/test/test_client.rb +1 -1
- data/test/test_fetch.rb +4 -0
- data/test/test_manager.rb +4 -3
- data/test/test_retry.rb +4 -0
- data/test/test_scheduling.rb +1 -0
- data/test/test_sidekiq.rb +2 -0
- data/test/test_web.rb +52 -15
- data/web/assets/javascripts/dashboard.js +134 -21
- data/web/assets/stylesheets/application.css +78 -310
- data/web/locales/en.yml +5 -0
- data/web/views/_job_info.erb +4 -4
- data/web/views/_poll.erb +1 -1
- data/web/views/busy.erb +27 -6
- data/web/views/dashboard.erb +19 -11
- data/web/views/morgue.erb +3 -3
- data/web/views/queue.erb +8 -7
- data/web/views/retries.erb +3 -3
- data/web/views/scheduled.erb +3 -3
- metadata +8 -8
data/web/views/dashboard.erb
CHANGED
@@ -1,15 +1,22 @@
|
|
1
1
|
<script type="text/javascript" src="<%= root_path %>javascripts/dashboard.js"></script>
|
2
|
+
<div class= "dashboard clearfix">
|
3
|
+
<h3 >
|
4
|
+
<%= t('Dashboard') %>
|
5
|
+
<span class="beacon">
|
6
|
+
<span class="ring"></span>
|
7
|
+
<span class="dot"></span>
|
8
|
+
</span>
|
9
|
+
</h3>
|
10
|
+
<div class="interval-slider">
|
11
|
+
<span class="interval-slider-label"><%= t('PollingInterval') %>:</span>
|
12
|
+
<span class="current-interval">2 sec</span>
|
13
|
+
<br/>
|
14
|
+
<input type="range" min="2000" max="20000" step="1000" value="2000"/>
|
15
|
+
</div>
|
16
|
+
</div>
|
2
17
|
|
3
|
-
<
|
4
|
-
|
5
|
-
<span class="beacon">
|
6
|
-
<span class="ring"></span>
|
7
|
-
<span class="dot"></span>
|
8
|
-
</span>
|
9
|
-
</h3>
|
10
|
-
|
11
|
-
<h5></h5>
|
12
|
-
<div id="realtime"></div>
|
18
|
+
<div id="realtime" data-processed-label="<%= t('Processed') %>" data-failed-label="<%= t('Failed') %>"></div>
|
19
|
+
<div id="realtime-legend"></div>
|
13
20
|
|
14
21
|
<h5>
|
15
22
|
<span class="history-heading"><%= t('History') %></span>
|
@@ -18,7 +25,8 @@
|
|
18
25
|
<a href="<%= root_path %>?days=90" class="history-graph <%= "active" if params[:days] == "90" %>"><%= t('ThreeMonths') %></a>
|
19
26
|
<a href="<%= root_path %>?days=180" class="history-graph <%= "active" if params[:days] == "180" %>"><%= t('SixMonths') %></a>
|
20
27
|
</h5>
|
21
|
-
<div id="history" data-processed="<%= h Sidekiq.dump_json(@processed_history) %>" data-failed="<%= h Sidekiq.dump_json(@failed_history) %>" data-update-url="<%= root_path %>dashboard/stats"></div>
|
28
|
+
<div id="history" data-processed-label="<%= t('Processed') %>" data-failed-label="<%= t('Failed') %>" data-processed="<%= h Sidekiq.dump_json(@processed_history) %>" data-failed="<%= h Sidekiq.dump_json(@failed_history) %>" data-update-url="<%= root_path %>dashboard/stats"></div>
|
29
|
+
<div id="history-legend"></div>
|
22
30
|
|
23
31
|
<br/>
|
24
32
|
<h5>Redis</h5>
|
data/web/views/morgue.erb
CHANGED
@@ -22,7 +22,7 @@
|
|
22
22
|
</th>
|
23
23
|
<th width="25%"><%= t('LastRetry') %></th>
|
24
24
|
<th><%= t('Queue') %></th>
|
25
|
-
<th><%= t('
|
25
|
+
<th><%= t('Job') %></th>
|
26
26
|
<th><%= t('Arguments') %></th>
|
27
27
|
<th><%= t('Error') %></th>
|
28
28
|
</tr>
|
@@ -40,9 +40,9 @@
|
|
40
40
|
<td>
|
41
41
|
<a href="<%= root_path %>queues/<%= entry.queue %>"><%= entry.queue %></a>
|
42
42
|
</td>
|
43
|
-
<td><%= entry.
|
43
|
+
<td><%= entry.display_class %></td>
|
44
44
|
<td>
|
45
|
-
<div class="args"><%= display_args(entry.
|
45
|
+
<div class="args"><%= display_args(entry.display_args) %></div>
|
46
46
|
</td>
|
47
47
|
<td>
|
48
48
|
<div><%= h truncate("#{entry['error_class']}: #{entry['error_message']}", 200) %></div>
|
data/web/views/queue.erb
CHANGED
@@ -13,25 +13,26 @@
|
|
13
13
|
</header>
|
14
14
|
<table class="queue table table-hover table-bordered table-striped">
|
15
15
|
<thead>
|
16
|
-
<th><%= t('
|
16
|
+
<th><%= t('Job') %></th>
|
17
17
|
<th><%= t('Arguments') %></th>
|
18
18
|
<th></th>
|
19
19
|
</thead>
|
20
20
|
<% @messages.each_with_index do |msg, index| %>
|
21
21
|
<tr>
|
22
|
-
<td><%= msg
|
22
|
+
<td><%= msg.display_class %></td>
|
23
23
|
<td>
|
24
|
-
<%
|
25
|
-
|
24
|
+
<% a = msg.display_args.inspect -%>
|
25
|
+
<% if a.size > 100 %>
|
26
|
+
<%= h(msg.display_args.inspect[0..100]) + "... " %>
|
26
27
|
<button data-toggle="collapse" data-target="#worker_<%= index %>" class="btn btn-default btn-xs"><%= t('ShowAll') %></button>
|
27
|
-
<div class="toggle" id="worker_<%= index %>" style="display: none;"><%= h(msg
|
28
|
+
<div class="toggle" id="worker_<%= index %>" style="display: none;"><%= h(msg.display_args) %></div>
|
28
29
|
<% else %>
|
29
|
-
<%= h(msg
|
30
|
+
<%= h(msg.display_args) %>
|
30
31
|
<% end %>
|
31
32
|
</td>
|
32
33
|
<td>
|
33
34
|
<form action="<%= root_path %>queues/<%= @name %>/delete" method="post">
|
34
|
-
<input name="key_val" value="<%= h Sidekiq.dump_json(msg) %>" type="hidden" />
|
35
|
+
<input name="key_val" value="<%= h Sidekiq.dump_json(msg.item) %>" type="hidden" />
|
35
36
|
<input class="btn btn-danger btn-xs" type="submit" name="delete" value="<%= t('Delete') %>" data-confirm="<%= t('AreYouSure') %>" />
|
36
37
|
</form>
|
37
38
|
</td>
|
data/web/views/retries.erb
CHANGED
@@ -23,7 +23,7 @@
|
|
23
23
|
<th width="25%"><%= t('NextRetry') %></th>
|
24
24
|
<th width="11%"><%= t('RetryCount') %></th>
|
25
25
|
<th><%= t('Queue') %></th>
|
26
|
-
<th><%= t('
|
26
|
+
<th><%= t('Job') %></th>
|
27
27
|
<th><%= t('Arguments') %></th>
|
28
28
|
<th><%= t('Error') %></th>
|
29
29
|
</tr>
|
@@ -42,9 +42,9 @@
|
|
42
42
|
<td>
|
43
43
|
<a href="<%= root_path %>queues/<%= entry.queue %>"><%= entry.queue %></a>
|
44
44
|
</td>
|
45
|
-
<td><%= entry.
|
45
|
+
<td><%= entry.display_class %></td>
|
46
46
|
<td>
|
47
|
-
<div class="args"><%= display_args(entry.
|
47
|
+
<div class="args"><%= display_args(entry.display_args) %></div>
|
48
48
|
</td>
|
49
49
|
<td>
|
50
50
|
<div><%= h truncate("#{entry['error_class']}: #{entry['error_message']}", 200) %></div>
|
data/web/views/scheduled.erb
CHANGED
@@ -21,7 +21,7 @@
|
|
21
21
|
</th>
|
22
22
|
<th width="25%"><%= t('When') %></th>
|
23
23
|
<th width="10%"><%= t('Queue') %></th>
|
24
|
-
<th><%= t('
|
24
|
+
<th><%= t('Job') %></th>
|
25
25
|
<th><%= t('Arguments') %></th>
|
26
26
|
</tr>
|
27
27
|
</thead>
|
@@ -36,9 +36,9 @@
|
|
36
36
|
<td>
|
37
37
|
<a href="<%= root_path %>queues/<%= entry.queue %>"><%= entry.queue %></a>
|
38
38
|
</td>
|
39
|
-
<td><%= entry.
|
39
|
+
<td><%= entry.display_class %></td>
|
40
40
|
<td>
|
41
|
-
<div class="args"><%= display_args(entry.
|
41
|
+
<div class="args"><%= display_args(entry.display_args) %></div>
|
42
42
|
</td>
|
43
43
|
</tr>
|
44
44
|
<% end %>
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sidekiq
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0
|
4
|
+
version: 3.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mike Perham
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-05-
|
11
|
+
date: 2014-05-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: redis
|
@@ -100,14 +100,14 @@ dependencies:
|
|
100
100
|
requirements:
|
101
101
|
- - "~>"
|
102
102
|
- !ruby/object:Gem::Version
|
103
|
-
version:
|
103
|
+
version: 5.3.3
|
104
104
|
type: :development
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
108
|
- - "~>"
|
109
109
|
- !ruby/object:Gem::Version
|
110
|
-
version:
|
110
|
+
version: 5.3.3
|
111
111
|
- !ruby/object:Gem::Dependency
|
112
112
|
name: rake
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|
@@ -126,16 +126,16 @@ dependencies:
|
|
126
126
|
name: rails
|
127
127
|
requirement: !ruby/object:Gem::Requirement
|
128
128
|
requirements:
|
129
|
-
- - "
|
129
|
+
- - "~>"
|
130
130
|
- !ruby/object:Gem::Version
|
131
|
-
version: 4.
|
131
|
+
version: 4.1.1
|
132
132
|
type: :development
|
133
133
|
prerelease: false
|
134
134
|
version_requirements: !ruby/object:Gem::Requirement
|
135
135
|
requirements:
|
136
|
-
- - "
|
136
|
+
- - "~>"
|
137
137
|
- !ruby/object:Gem::Version
|
138
|
-
version: 4.
|
138
|
+
version: 4.1.1
|
139
139
|
- !ruby/object:Gem::Dependency
|
140
140
|
name: coveralls
|
141
141
|
requirement: !ruby/object:Gem::Requirement
|