sidekiq_utils 1.0.0 → 1.0.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
  SHA1:
3
- metadata.gz: b3f6eac2a6e7d56402251588cfe585dd2ab0b489
4
- data.tar.gz: 2b5c6aab41b220464b6ce061f66128be1a9ac006
3
+ metadata.gz: 25e7a645fef4b5bfc9dd087e14785e939af10b17
4
+ data.tar.gz: ec028e2cde1ef2eb36345451b4366f79f96afe0c
5
5
  SHA512:
6
- metadata.gz: 33f07d894defb62273a7722d19c4ee604cef8a4c9f9f17291a82e89f7614632f108fc58e8fdb8420a5407d6a0f5c07d18125e69b4a92f762614d24b9e6be52e7
7
- data.tar.gz: 124dde56aa5b9bd3525974e42177b6a1ccd4ec4340d98fdee0fba8a4d0ae106825a560a5bdd0a111842297fbfdc1870ff6f5ad1dad5f439d631bc07ec68a9987
6
+ metadata.gz: a4820e308d2e810f52da0c6d91fa0a3289f016771f0414e0f2ca4a2552f1069bb5d3867568b615fb9c98def6d8190c940947e125e773931b9de124301f73dd7f
7
+ data.tar.gz: cf7aba28bfcf07849865492033aafc785972d67f0bbdc5dae7a47f2aac36ab0e8ffff75587b08eff9290003c392cf285a81fd20d6d719d9dc4c92961a79b3b4d
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.0
1
+ 1.0.1
@@ -8,9 +8,11 @@ module SidekiqUtils
8
8
  def check!
9
9
  alerts = {}
10
10
  Sidekiq::Queue.all.each do |queue|
11
- threshold = config['alert_thresholds'][queue.name]
11
+ threshold = config['alert_thresholds'][queue.name].
12
+ try!(&:to_i).try!(:minutes)
12
13
  next if threshold == :disabled
13
- threshold ||= config['alert_thresholds']['default'] || 10.minutes
14
+ threshold ||= config['alert_thresholds']['default'].
15
+ try!(&:to_i).try!(:minutes) || 10.minutes
14
16
  if (latency = queue.latency) > threshold
15
17
  alerts[queue.name] = latency
16
18
  end
@@ -2,11 +2,11 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Juwelier::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: sidekiq_utils 1.0.0 ruby lib
5
+ # stub: sidekiq_utils 1.0.1 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "sidekiq_utils".freeze
9
- s.version = "1.0.0"
9
+ s.version = "1.0.1"
10
10
 
11
11
  s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
12
12
  s.require_paths = ["lib".freeze]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sidekiq_utils
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Magnus von Koeller