flapjack 1.3.0rc2 → 1.3.0rc3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/flapjack/data/alert.rb +1 -0
- data/lib/flapjack/data/event.rb +1 -0
- data/lib/flapjack/data/migration.rb +1 -1
- data/lib/flapjack/data/notification.rb +2 -1
- data/lib/flapjack/gateways/aws_sns.rb +2 -1
- data/lib/flapjack/gateways/email.rb +2 -1
- data/lib/flapjack/gateways/sms_messagenet.rb +2 -1
- data/lib/flapjack/gateways/sms_nexmo.rb +2 -1
- data/lib/flapjack/gateways/sms_twilio.rb +2 -1
- data/lib/flapjack/notifier.rb +1 -1
- data/lib/flapjack/version.rb +1 -1
- metadata +2 -5
- data/dist/etc/init.d/flapjack +0 -32
- data/dist/etc/init.d/flapjack-nagios-receiver +0 -21
- data/dist/etc/init.d/flapper +0 -18
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3a99054ee2b384d5e9c228122908ccf56025729a
|
4
|
+
data.tar.gz: 9f460d85068057cf8063ebce88c199470efe8c91
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 80ecfea159a7b1267f1288f32a2c672da1d73519fa9befc25299915eb786e24f577928737c05f04f339ac4eb00fbdc7312dcb64596c66c127a39fc0099125d18
|
7
|
+
data.tar.gz: d84a6a4b1cc227717f1b2b3ed91699d2908f4de32e44eab6f576b64cd5224e4fba189bed5341764d518a0dad2b1326b4b5eef568b718328ec6c13437b6f5608e
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,9 @@
|
|
1
1
|
## Flapjack Changelog
|
2
2
|
|
3
|
+
# 1.3.0rc3 - 2015-02-17
|
4
|
+
- Bug: cleanup gateway shutdown logic, fix #789 #790 (@ali-graham)
|
5
|
+
- Chore: move init scripts to omnibus-flapjack repo (@Hobbsee)
|
6
|
+
|
3
7
|
# 1.3.0rc2 - 2015-02-13
|
4
8
|
- Bug: Error uninstalling - Error generating or dispatching SMS Nexmo message #789 (@Hobbsee)
|
5
9
|
|
data/lib/flapjack/data/alert.rb
CHANGED
data/lib/flapjack/data/event.rb
CHANGED
@@ -205,7 +205,7 @@ module Flapjack
|
|
205
205
|
|
206
206
|
return if redis.exists('validated_scheduled_maintenance_periods')
|
207
207
|
|
208
|
-
Flapjack::Data::EntityCheck.all(:redis => redis).select {|ec|
|
208
|
+
Flapjack::Data::EntityCheck.all(:redis => redis).compact.select {|ec|
|
209
209
|
ec.in_scheduled_maintenance?
|
210
210
|
}.each do |check|
|
211
211
|
check.update_current_scheduled_maintenance(:revalidate => true)
|
@@ -45,7 +45,8 @@ module Flapjack
|
|
45
45
|
until @should_quit
|
46
46
|
begin
|
47
47
|
@logger.debug("aws_sns gateway is going into blpop mode on #{queue}")
|
48
|
-
|
48
|
+
alert = Flapjack::Data::Alert.next(queue, :redis => @redis, :logger => @logger)
|
49
|
+
deliver(alert) unless alert.nil?
|
49
50
|
rescue => e
|
50
51
|
@logger.error "Error generating or dispatching AWS SNS message: #{e.class}: #{e.message}\n" +
|
51
52
|
e.backtrace.join("\n")
|
@@ -51,7 +51,8 @@ module Flapjack
|
|
51
51
|
until @should_quit
|
52
52
|
begin
|
53
53
|
@logger.debug("email gateway is going into blpop mode on #{queue}")
|
54
|
-
|
54
|
+
alert = Flapjack::Data::Alert.next(queue, :redis => @redis, :logger => @logger)
|
55
|
+
deliver(alert) unless alert.nil?
|
55
56
|
rescue => e
|
56
57
|
@logger.error "Error generating or dispatching email message: #{e.class}: #{e.message}\n" +
|
57
58
|
e.backtrace.join("\n")
|
@@ -45,7 +45,8 @@ module Flapjack
|
|
45
45
|
until @should_quit
|
46
46
|
begin
|
47
47
|
@logger.debug("sms_messagenet gateway is going into blpop mode on #{queue}")
|
48
|
-
|
48
|
+
alert = Flapjack::Data::Alert.next(queue, :redis => @redis, :logger => @logger)
|
49
|
+
deliver(alert) unless alert.nil?
|
49
50
|
rescue => e
|
50
51
|
@logger.error "Error generating or dispatching SMS Messagenet message: #{e.class}: #{e.message}\n" +
|
51
52
|
e.backtrace.join("\n")
|
@@ -45,7 +45,8 @@ module Flapjack
|
|
45
45
|
until @should_quit
|
46
46
|
begin
|
47
47
|
@logger.debug("sms_nexmo gateway is going into blpop mode on #{queue}")
|
48
|
-
|
48
|
+
alert = Flapjack::Data::Alert.next(queue, :redis => @redis, :logger => @logger)
|
49
|
+
deliver(alert) unless alert.nil?
|
49
50
|
rescue => e
|
50
51
|
@logger.error "Error generating or dispatching SMS Nexmo message: #{e.class}: #{e.message}\n" +
|
51
52
|
e.backtrace.join("\n")
|
@@ -49,7 +49,8 @@ module Flapjack
|
|
49
49
|
until @should_quit
|
50
50
|
begin
|
51
51
|
@logger.debug("sms_twilio gateway is going into blpop mode on #{queue}")
|
52
|
-
|
52
|
+
alert = Flapjack::Data::Alert.next(queue, :redis => @redis, :logger => @logger)
|
53
|
+
deliver(alert) unless alert.nil?
|
53
54
|
rescue => e
|
54
55
|
@logger.error "Error generating or dispatching SMS Twilio message: #{e.class}: #{e.message}\n" +
|
55
56
|
e.backtrace.join("\n")
|
data/lib/flapjack/notifier.rb
CHANGED
@@ -66,7 +66,7 @@ module Flapjack
|
|
66
66
|
notification = Flapjack::Data::Notification.next(@notifications_queue,
|
67
67
|
:redis => @redis,
|
68
68
|
:logger => @logger)
|
69
|
-
process_notification(notification) unless notification.nil?
|
69
|
+
process_notification(notification) unless notification.nil?
|
70
70
|
end
|
71
71
|
|
72
72
|
@logger.info("Exiting main loop.")
|
data/lib/flapjack/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: flapjack
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.3.
|
4
|
+
version: 1.3.0rc3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lindsay Holmwood
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date: 2015-02-
|
14
|
+
date: 2015-02-17 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: dante
|
@@ -387,9 +387,6 @@ files:
|
|
387
387
|
- Rakefile
|
388
388
|
- bin/flapjack
|
389
389
|
- build.sh
|
390
|
-
- dist/etc/init.d/flapjack
|
391
|
-
- dist/etc/init.d/flapjack-nagios-receiver
|
392
|
-
- dist/etc/init.d/flapper
|
393
390
|
- etc/flapjack_config.yaml.example
|
394
391
|
- features/ack_after_sched_maint.feature
|
395
392
|
- features/cli.feature
|
data/dist/etc/init.d/flapjack
DELETED
@@ -1,32 +0,0 @@
|
|
1
|
-
#!/bin/bash
|
2
|
-
|
3
|
-
### BEGIN INIT INFO
|
4
|
-
# Provides: flapjack
|
5
|
-
# Required-Start: $syslog $remote_fs redis-flapjack
|
6
|
-
# Required-Stop: $syslog $remote_fs redis-flapjack
|
7
|
-
# Should-Start: $local_fs
|
8
|
-
# Should-Stop: $local_fs
|
9
|
-
# Default-Start: 2 3 4 5
|
10
|
-
# Default-Stop: 0 1 6
|
11
|
-
# Short-Description: flapjack - scalable monitoring notification system
|
12
|
-
# Description: flapjack - scalable monitoring notification system
|
13
|
-
### END INIT INFO
|
14
|
-
|
15
|
-
# Copyright (c) 2009-2013 Lindsay Holmwood <lindsay@holmwood.id.au>
|
16
|
-
#
|
17
|
-
# Boots flapjack (coordinator, processor, notifier, gateways...)
|
18
|
-
|
19
|
-
PATH=/opt/flapjack/bin:$PATH
|
20
|
-
|
21
|
-
if [ ! $(which flapjack) ]; then
|
22
|
-
echo "Error: flapjack isn't in PATH."
|
23
|
-
echo "Refusing to do anything!"
|
24
|
-
exit 1
|
25
|
-
fi
|
26
|
-
|
27
|
-
# Evaluate command
|
28
|
-
flapjack server $@
|
29
|
-
|
30
|
-
RETVAL=$?
|
31
|
-
exit $RETVAL
|
32
|
-
|
@@ -1,21 +0,0 @@
|
|
1
|
-
#!/bin/bash
|
2
|
-
#
|
3
|
-
# Copyright (c) 2009-2013 Lindsay Holmwood <lindsay@holmwood.id.au>
|
4
|
-
#
|
5
|
-
# flapjack-nagios-receiver
|
6
|
-
# reads from a nagios perfdata named-pipe and submits each event to the events queue in redis
|
7
|
-
#
|
8
|
-
|
9
|
-
PATH=/opt/flapjack/bin:$PATH
|
10
|
-
|
11
|
-
if [ ! $(which flapjack) ]; then
|
12
|
-
echo "Error: flapjack isn't in PATH."
|
13
|
-
echo "Refusing to do anything!"
|
14
|
-
exit 1
|
15
|
-
fi
|
16
|
-
|
17
|
-
# Evaluate command
|
18
|
-
flapjack receiver nagios $1 --daemonize
|
19
|
-
|
20
|
-
RETVAL=$?
|
21
|
-
exit $RETVAL
|
data/dist/etc/init.d/flapper
DELETED
@@ -1,18 +0,0 @@
|
|
1
|
-
#!/bin/bash
|
2
|
-
#
|
3
|
-
# flapper
|
4
|
-
#
|
5
|
-
|
6
|
-
PATH=/opt/flapjack/bin:$PATH
|
7
|
-
|
8
|
-
if [ ! $(which flapjack) ]; then
|
9
|
-
echo "Error: flapjack isn't in PATH."
|
10
|
-
echo "Refusing to do anything!"
|
11
|
-
exit 1
|
12
|
-
fi
|
13
|
-
|
14
|
-
# Evaluate command
|
15
|
-
flapjack flapper $1
|
16
|
-
|
17
|
-
RETVAL=$?
|
18
|
-
exit $RETVAL
|