job_state 0.0.12 → 0.0.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 672e848f5e7cd27e743fe7ce15835e757f698b71a7dd2fd494f9ef9e1b9eafcc
|
4
|
+
data.tar.gz: c334c57dab6d87dbc88a98640c93c2feb6cd56c58eb1aa218ee0fa9df9294196
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f009eca345fd7a910d9d569749e2d9231c31fc3739bd7551a4454f41e5fd43c07ccfb0af708f456be5661aad311477242dea54c8e777a71e6d1e8b743c94520e
|
7
|
+
data.tar.gz: 6fa0d39d19063fa0db1c9488b04836615d1cd376288375517d5165f1a99a356665722f6d57e1bee87a05fd13a579fc221e7d6cbb85067c6c4d41854a245f7d60
|
@@ -11,6 +11,14 @@
|
|
11
11
|
self._poll();
|
12
12
|
};
|
13
13
|
|
14
|
+
self.killJob = function() {
|
15
|
+
$.ajax({
|
16
|
+
url: '/job_state/job_states/' + self._jobUuid + '/kill',
|
17
|
+
type: 'POST',
|
18
|
+
dataType: 'json'
|
19
|
+
});
|
20
|
+
}
|
21
|
+
|
14
22
|
self._poll = function() {
|
15
23
|
setTimeout(function() {
|
16
24
|
$.ajax({
|
@@ -3,7 +3,7 @@ module JobState
|
|
3
3
|
|
4
4
|
respond_to :html, :json
|
5
5
|
|
6
|
-
before_action :fetch_job_state
|
6
|
+
before_action :fetch_job_state
|
7
7
|
|
8
8
|
def show
|
9
9
|
respond_to do |format|
|
@@ -13,6 +13,11 @@ module JobState
|
|
13
13
|
end
|
14
14
|
end
|
15
15
|
|
16
|
+
def kill
|
17
|
+
@job_state.kill
|
18
|
+
head :ok
|
19
|
+
end
|
20
|
+
|
16
21
|
private
|
17
22
|
|
18
23
|
def fetch_job_state
|
data/config/routes.rb
CHANGED
data/lib/job_state/base.rb
CHANGED
@@ -123,6 +123,14 @@ module JobState
|
|
123
123
|
@job_uuid
|
124
124
|
end
|
125
125
|
|
126
|
+
#**********************************************************************
|
127
|
+
# KILLING
|
128
|
+
#
|
129
|
+
# This method kills the job
|
130
|
+
def kill
|
131
|
+
Resque::Plugins::Status::Hash.kill(@job_uuid)
|
132
|
+
end
|
133
|
+
|
126
134
|
private
|
127
135
|
|
128
136
|
def status_hash
|
data/lib/job_state/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: job_state
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.13
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Wyatt Greene
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date:
|
13
|
+
date: 2025-02-10 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: rails
|
@@ -116,43 +116,43 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
116
116
|
- !ruby/object:Gem::Version
|
117
117
|
version: '0'
|
118
118
|
requirements: []
|
119
|
-
rubygems_version: 3.
|
119
|
+
rubygems_version: 3.3.27
|
120
120
|
signing_key:
|
121
121
|
specification_version: 4
|
122
122
|
summary: This engine provides a way to poll resque jobs for their status and display
|
123
123
|
to the user.
|
124
124
|
test_files:
|
125
|
-
- test/dummy/
|
126
|
-
- test/dummy/
|
125
|
+
- test/dummy/README.rdoc
|
126
|
+
- test/dummy/Rakefile
|
127
127
|
- test/dummy/app/assets/javascripts/application.js
|
128
128
|
- test/dummy/app/assets/stylesheets/application.css
|
129
|
+
- test/dummy/app/controllers/application_controller.rb
|
129
130
|
- test/dummy/app/helpers/application_helper.rb
|
130
|
-
- test/dummy/
|
131
|
+
- test/dummy/app/views/layouts/application.html.erb
|
131
132
|
- test/dummy/bin/bundle
|
132
133
|
- test/dummy/bin/rails
|
133
|
-
- test/dummy/
|
134
|
-
- test/dummy/config/locales/en.yml
|
135
|
-
- test/dummy/config/environments/production.rb
|
136
|
-
- test/dummy/config/environments/development.rb
|
137
|
-
- test/dummy/config/environments/test.rb
|
138
|
-
- test/dummy/config/environment.rb
|
134
|
+
- test/dummy/bin/rake
|
139
135
|
- test/dummy/config/application.rb
|
140
|
-
- test/dummy/config/database.yml
|
141
136
|
- test/dummy/config/boot.rb
|
137
|
+
- test/dummy/config/database.yml
|
138
|
+
- test/dummy/config/environment.rb
|
139
|
+
- test/dummy/config/environments/development.rb
|
140
|
+
- test/dummy/config/environments/production.rb
|
141
|
+
- test/dummy/config/environments/test.rb
|
142
142
|
- test/dummy/config/initializers/backtrace_silencers.rb
|
143
|
-
- test/dummy/config/initializers/mime_types.rb
|
144
143
|
- test/dummy/config/initializers/filter_parameter_logging.rb
|
144
|
+
- test/dummy/config/initializers/inflections.rb
|
145
|
+
- test/dummy/config/initializers/mime_types.rb
|
146
|
+
- test/dummy/config/initializers/secret_token.rb
|
145
147
|
- test/dummy/config/initializers/session_store.rb
|
146
148
|
- test/dummy/config/initializers/wrap_parameters.rb
|
147
|
-
- test/dummy/config/
|
148
|
-
- test/dummy/config/
|
149
|
+
- test/dummy/config/locales/en.yml
|
150
|
+
- test/dummy/config/routes.rb
|
149
151
|
- test/dummy/config.ru
|
150
|
-
- test/dummy/
|
151
|
-
- test/dummy/public/favicon.ico
|
152
|
+
- test/dummy/public/404.html
|
152
153
|
- test/dummy/public/422.html
|
153
154
|
- test/dummy/public/500.html
|
154
|
-
- test/dummy/public/
|
155
|
-
- test/dummy/README.rdoc
|
155
|
+
- test/dummy/public/favicon.ico
|
156
156
|
- test/integration/navigation_test.rb
|
157
157
|
- test/job_state_test.rb
|
158
158
|
- test/test_helper.rb
|