misha-resque-web 0.0.9 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4af4c98761a29cde1a2a00cd66dbee7e49bb5ffa
|
4
|
+
data.tar.gz: 9af27895232d266e08703495e91e995b1184fcb8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d61fe1e42373f600961e3466713cb8dc42296a7edc1cad9d978a72c49bdd35369f2934ce38db433ed29282d4407a8c519efca8b2de37c075033fe95de0c6c9db
|
7
|
+
data.tar.gz: a511e3603e818040e95dbc8bea9b8ca6201016d9878dbeb93d91ca57af80a37a2575049a65ba65a884e9e3cf49948894629c69e0905a87927be2d5f60214010d
|
@@ -0,0 +1,34 @@
|
|
1
|
+
module ResqueWeb
|
2
|
+
class DelayedController < ResqueWeb::ApplicationController
|
3
|
+
|
4
|
+
# Display all jobs in the failure queue
|
5
|
+
#
|
6
|
+
# @param [Hash] params
|
7
|
+
# @option params [String] :class filters failures shown by class
|
8
|
+
# @option params [String] :queue filters failures shown by failure queue name
|
9
|
+
def index
|
10
|
+
if params[:klass].present?
|
11
|
+
Resque.find_delayed_selection('Dsc::Jobs::Marketing::ActivateScheduledCampaignCommunication'){ |i| puts i; true }
|
12
|
+
|
13
|
+
end
|
14
|
+
end
|
15
|
+
|
16
|
+
# remove an individual job from the failure queue
|
17
|
+
def destroy
|
18
|
+
Resque::Failure.remove(params[:id])
|
19
|
+
redirect_to failures_path(redirect_params)
|
20
|
+
end
|
21
|
+
|
22
|
+
# destroy all jobs from the failure queue
|
23
|
+
def destroy_all
|
24
|
+
queue = params[:queue] || 'failed'
|
25
|
+
Resque::Failure.clear(queue)
|
26
|
+
redirect_to failures_path(redirect_params)
|
27
|
+
end
|
28
|
+
|
29
|
+
|
30
|
+
|
31
|
+
private
|
32
|
+
|
33
|
+
end
|
34
|
+
end
|
@@ -0,0 +1 @@
|
|
1
|
+
delayed index....
|
@@ -1,5 +1,5 @@
|
|
1
1
|
<% if multiple_failure_queues? && !params[:queue] %>
|
2
|
-
<h1>All Failure
|
2
|
+
<h1>All Failure Queues222</h1>
|
3
3
|
<% else %>
|
4
4
|
<h1>Failed Jobs <%= "on '#{params[:queue]}'" if params[:queue] %> <%= "with class '#{params[:class]}'" if params[:class] %></h1>
|
5
5
|
<% end %>
|
data/lib/resque_web/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: misha-resque-web
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0
|
4
|
+
version: 0.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tony Arcieri
|
@@ -103,6 +103,7 @@ files:
|
|
103
103
|
- app/assets/stylesheets/resque_web/application.css
|
104
104
|
- app/assets/stylesheets/resque_web/bootstrap_and_overrides.css.scss.erb
|
105
105
|
- app/controllers/resque_web/application_controller.rb
|
106
|
+
- app/controllers/resque_web/delayed_controller.rb
|
106
107
|
- app/controllers/resque_web/failures_controller.rb
|
107
108
|
- app/controllers/resque_web/overview_controller.rb
|
108
109
|
- app/controllers/resque_web/queues_controller.rb
|
@@ -117,6 +118,7 @@ files:
|
|
117
118
|
- app/helpers/resque_web/workers_helper.rb
|
118
119
|
- app/helpers/resque_web/working_helper.rb
|
119
120
|
- app/views/layouts/resque_web/application.html.erb
|
121
|
+
- app/views/resque_web/delayed/index.html.erb
|
120
122
|
- app/views/resque_web/failures/_failed_job.html.erb
|
121
123
|
- app/views/resque_web/failures/_overview.html.erb
|
122
124
|
- app/views/resque_web/failures/index.html.erb
|