hq-log-monitor-server 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/features/overview.feature +1 -0
- data/lib/hq/log-monitor-server/script.rb +13 -2
- metadata +1 -1
data/features/overview.feature
CHANGED
@@ -57,7 +57,12 @@ class Script
|
|
57
57
|
|
58
58
|
loop do
|
59
59
|
sleep 1 while Time.now < @next_check
|
60
|
-
|
60
|
+
begin
|
61
|
+
do_checks
|
62
|
+
rescue => e
|
63
|
+
$stderr.puts e, *e.backtrace
|
64
|
+
sleep 10
|
65
|
+
end
|
61
66
|
end
|
62
67
|
|
63
68
|
end
|
@@ -74,11 +79,17 @@ class Script
|
|
74
79
|
@icinga_elem.find("service").each do
|
75
80
|
|service_elem|
|
76
81
|
|
82
|
+
service_name = service_elem["name"]
|
83
|
+
|
77
84
|
critical_count = 0
|
78
85
|
warning_count = 0
|
79
86
|
unknown_count = 0
|
80
87
|
|
81
|
-
summaries_by_service[
|
88
|
+
summaries = summaries_by_service[service_name]
|
89
|
+
|
90
|
+
next unless summaries
|
91
|
+
|
92
|
+
summaries["types"].each do
|
82
93
|
|type_name, type_info|
|
83
94
|
|
84
95
|
type_elem =
|