sumo-check-sumo 0.0.27 → 0.0.28

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: d22d16a3915bb7935f33032d91b7369bee56e107
4
- data.tar.gz: 48b3c276edbde05104aa2ffa5faf8535898bdbcd
3
+ metadata.gz: 59cf38cc84eb6fe24f1253c8ac32a9899cc79057
4
+ data.tar.gz: d9ada7d3bf6f5236947e3d9c96d37fc11443c042
5
5
  SHA512:
6
- metadata.gz: 20eabaa30e7141c21eb85488e75156cfde8bea1bee721724f4ed90a3aa392ee42d1a1f8f95d763bbced5204e1c295178dc4f150c1e704bc6d888c171ff62a276
7
- data.tar.gz: d671e68f6deba3eea9107357b6122869d2db09e3e8722a5df080dc497a4982e7053299ec849aa0d74d4ec353ceb2e7a4159b21a16b69d7bb177ff87be03fd00b
6
+ metadata.gz: a08160a01084cff3d00eb6b5187e2cf08dea780e358e776fbfa5ae5ca364fa9e7789677f2b1cd9f2a6b427ce450198447e048f8f212a6bb961ecab2d97d8d5b9
7
+ data.tar.gz: dcd20220e7ff48c1403fb85e63040c6b80ad67176fd597ab27efc10fea268b8f272b9ec1d4823f32851adfb008034c8b95598f7ad1e5a69aae532c7812071610
@@ -17,7 +17,7 @@ class SumoMessageCenterMetrics < Sensu::Plugin::Metric::CLI::Graphite
17
17
  list_types = db.query("select DISTINCT email_list_type from SumoMailEmail;",:as => :array).to_a.flatten
18
18
  list_types.each do |type|
19
19
  metrics.each do |m|
20
- result = db.query("SELECT count(id) FROM SumoMailEmail where state='#{m}' and email_list_type='#{type}';")
20
+ result = db.query("SELECT count(id) FROM SumoMailEmail where state='#{m}' and email_list_type='#{type}' and scheduled_for <= NOW() - INTERVAL 10 MINUTE;")
21
21
  if result.count > 0
22
22
  output "#{check_prefix_name}.#{type}.#{m}.count".tr(' ', '_'),result.first["count(id)"].to_i,Time.now.to_i
23
23
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sumo-check-sumo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.27
4
+ version: 0.0.28
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dr. Ogg