resque-job-stats-promptcloud 0.1.0 → 0.4.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/resque/plugins/job_stats.rb +1 -1
- data/lib/resque/plugins/job_stats/duration.rb +1 -1
- data/lib/resque/plugins/job_stats/enqueued.rb +1 -1
- data/lib/resque/plugins/job_stats/failed.rb +1 -1
- data/lib/resque/plugins/job_stats/measured_hook.rb +12 -2
- data/lib/resque/plugins/job_stats/performed.rb +1 -1
- data/lib/resque/plugins/job_stats/timeseries.rb +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 06d87a6861cf9541cc06b31b312f799a5f5245b4
|
4
|
+
data.tar.gz: 9220774bd94c797b3f515ff8ab5b643d9b31df8a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e10c62291a483273d3a4fe0d7480895b351cc498ac03e6156ce90f3c53f592d326c5f1af2992fbc87b5c91aee238de8a81cb356b412554de7e094b3e0aeadc6a
|
7
|
+
data.tar.gz: 6a368ccf00534d11adfb272807d922b8381b7643149f1b76bf948cd7a3f012d83907e048a7fe09487a7cc88edc03a2581fd7b731db0094e1278f822ce8da77ea
|
@@ -11,7 +11,7 @@ require 'resque/plugins/job_stats/history'
|
|
11
11
|
module Resque
|
12
12
|
module Plugins
|
13
13
|
module JobStats
|
14
|
-
|
14
|
+
include Resque::Plugins::JobStats::MeasuredHook
|
15
15
|
include Resque::Plugins::JobStats::Performed
|
16
16
|
include Resque::Plugins::JobStats::Enqueued
|
17
17
|
include Resque::Plugins::JobStats::Failed
|
@@ -5,7 +5,7 @@ module Resque
|
|
5
5
|
# Extend your job with this module to track how many
|
6
6
|
# jobs are queued successfully
|
7
7
|
module Enqueued
|
8
|
-
|
8
|
+
include Resque::Plugins::JobStats::MeasuredHook
|
9
9
|
|
10
10
|
# Sets the number of jobs queued
|
11
11
|
def jobs_enqueued=(int)
|
@@ -3,8 +3,18 @@ module Resque
|
|
3
3
|
module JobStats
|
4
4
|
module MeasuredHook
|
5
5
|
|
6
|
-
def
|
7
|
-
|
6
|
+
def self.included(base)
|
7
|
+
base.extend ClassMethods
|
8
|
+
end
|
9
|
+
|
10
|
+
module ClassMethods
|
11
|
+
def extended(base)
|
12
|
+
Resque::Plugins::JobStats.add_measured_job(base)
|
13
|
+
end
|
14
|
+
end
|
15
|
+
|
16
|
+
def inherited(subclass)
|
17
|
+
subclass.extend Resque::Plugins::JobStats
|
8
18
|
end
|
9
19
|
|
10
20
|
end
|
@@ -5,7 +5,7 @@ module Resque
|
|
5
5
|
# Extend your job with this module to track how many
|
6
6
|
# jobs are performed successfully
|
7
7
|
module Performed
|
8
|
-
|
8
|
+
include Resque::Plugins::JobStats::MeasuredHook
|
9
9
|
|
10
10
|
# Sets the number of jobs performed
|
11
11
|
def jobs_performed=(int)
|
@@ -57,7 +57,7 @@ module Resque
|
|
57
57
|
end
|
58
58
|
|
59
59
|
module Resque::Plugins::JobStats::Timeseries::Enqueued
|
60
|
-
|
60
|
+
include Resque::Plugins::JobStats::MeasuredHook
|
61
61
|
include Resque::Plugins::JobStats::Timeseries::Common
|
62
62
|
|
63
63
|
# Increments the enqueued count for the timestamp when job is queued
|
@@ -77,7 +77,7 @@ module Resque::Plugins::JobStats::Timeseries::Enqueued
|
|
77
77
|
end
|
78
78
|
|
79
79
|
module Resque::Plugins::JobStats::Timeseries::Performed
|
80
|
-
|
80
|
+
include Resque::Plugins::JobStats::MeasuredHook
|
81
81
|
include Resque::Plugins::JobStats::Timeseries::Common
|
82
82
|
|
83
83
|
# Increments the performed count for the timestamp when job is complete
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: resque-job-stats-promptcloud
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- alanpeabody
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-11-
|
11
|
+
date: 2018-11-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: resque
|