sidekiq-cronitor 3.7.0 → 3.7.1
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: df6cdfd744692fd8210ed7ef0e6a3845b35d3f268141ff83093fb9a0fe710387
|
4
|
+
data.tar.gz: b3e6120323ea9859e142f2726d18a0f172468e4c91a8b2175805f28f39298dbe
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8b7896c002b1e9781b1156095968fadfdcbd7b560caf0f125c55ccdf20d9097021fb25029f8b7eb2b31c2fef2682445767e00502c50ba558188303f8024d3d8e
|
7
|
+
data.tar.gz: 576c4abccc65dba09da848161a8526ba058ee92279a7969da61a53b4d8105535aacf6500682274e1bb28f0d21fdd3dafe4173cf405eea3151ffc97d7f39e6476
|
@@ -6,7 +6,7 @@ module Sidekiq::Cronitor
|
|
6
6
|
monitors_payload = []
|
7
7
|
loops = Sidekiq::Periodic::LoopSet.new
|
8
8
|
loops.each do |lop|
|
9
|
-
if
|
9
|
+
if lop.options.has_key?('cronitor_enabled') || lop.klass.constantize.sidekiq_options.has_key?('cronitor_enabled')
|
10
10
|
next unless fetch_option(lop, 'cronitor_enabled', Cronitor.auto_discover_sidekiq)
|
11
11
|
else
|
12
12
|
next if fetch_option(lop, 'cronitor_disabled', !Cronitor.auto_discover_sidekiq)
|
@@ -13,7 +13,7 @@ module Sidekiq::Cronitor
|
|
13
13
|
job_klass = Object.const_get(v['class'])
|
14
14
|
job_key = job_klass.sidekiq_options.fetch('cronitor_key', v['class'])
|
15
15
|
|
16
|
-
if job_klass.sidekiq_options
|
16
|
+
if job_klass.sidekiq_options.has_key?('cronitor_enabled')
|
17
17
|
next unless job_klass.sidekiq_options.fetch('cronitor_enabled', Cronitor.auto_discover_sidekiq)
|
18
18
|
else
|
19
19
|
next if job_klass.sidekiq_options.fetch('cronitor_disabled', !Cronitor.auto_discover_sidekiq)
|
data/lib/sidekiq/cronitor.rb
CHANGED
@@ -33,7 +33,7 @@ module Sidekiq::Cronitor
|
|
33
33
|
end
|
34
34
|
|
35
35
|
def cronitor_disabled?(worker)
|
36
|
-
if worker.class.sidekiq_options
|
36
|
+
if worker.class.sidekiq_options.has_key?("cronitor_enabled")
|
37
37
|
!worker.class.sidekiq_options.fetch("cronitor_enabled", Cronitor.auto_discover_sidekiq)
|
38
38
|
else
|
39
39
|
worker.class.sidekiq_options.fetch("cronitor_disabled", options(worker).fetch(:disabled, !Cronitor.auto_discover_sidekiq))
|