riemann-babbler 2.0.8 → 2.0.9
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 +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +16 -14
- data/lib/riemann/babbler/plugins/responder_udp.rb +4 -3
- data/lib/riemann/babbler/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7e9ad3871d5faafd9bb513bbb6f69d12866aba0f
|
4
|
+
data.tar.gz: 98d26cec3306e66836ce14897e6e04cbdccf0ff4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 25024bbe9e34cac4aeee831b9cc6917109d66c420f84d4c88166d811e3ddcc20a1f33e7f54a28d16f397395edf62c41cea1a205e77a4b7d5b2e7b2683dfd1573
|
7
|
+
data.tar.gz: 522f4f4b86150acdd1e2c381ccceb1becfd1f7dc2dac43d4016779a547fa8bb6cc2ca41620e099f91fc83bd193220a31ad4cceeb2ee8bb340931d4c277991fea
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -13,19 +13,21 @@ Riemann-babbler is tool for monitoring with riemann.
|
|
13
13
|
Usage:
|
14
14
|
riemann-babbler [options]
|
15
15
|
where [options] are:
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
16
|
+
--config, -c <s>: Config file (default: /etc/riemann-babbler/config.yml)
|
17
|
+
--host, -h <s>: Riemann host (default: 127.0.0.1)
|
18
|
+
--port, -p <i>: Riemann port (default: 5555)
|
19
|
+
--timeout, -t <i>: Riemann timeout (default: 5)
|
20
|
+
--fqdn, --no-fqdn, -f: Use fqdn for event hostname (default: true)
|
21
|
+
--ttl, -l <i>: TTL for events (default: 60)
|
22
|
+
--interval, -i <i>: Seconds between updates (default: 60)
|
23
|
+
--log-level, -o <s>: Level log (default: DEBUG)
|
24
|
+
--plugins-directory, -u <s>: Directory for plugins (default: /usr/share/riemann-babbler/plugins)
|
25
|
+
--tcp, --no-tcp: Use TCP transport instead of UDP (improves reliability, slight overhead. (Default: true)
|
26
|
+
--minimize-event-count, --no-minimize-event-count, -m: Minimize count of sent messages (default: true)
|
27
|
+
--responder-http-port, -r <i>: Port to bind http responder (default: 55755)
|
28
|
+
--responder-udp-port, -e <i>: Port to bind tcp responder (default: 55955)
|
29
|
+
--version, -v: Print version and exit
|
30
|
+
--help: Show this message
|
29
31
|
```
|
30
32
|
|
31
33
|
### Config
|
@@ -101,4 +103,4 @@ class Riemann::Babbler::Plugin::AwesomePlugin < Riemann::Babbler::Plugin
|
|
101
103
|
status
|
102
104
|
end
|
103
105
|
end
|
104
|
-
```
|
106
|
+
```
|
@@ -9,9 +9,10 @@ class Riemann::Babbler::Plugin::ResponderUdp < Riemann::Babbler::Plugin
|
|
9
9
|
|
10
10
|
def process(data, src)
|
11
11
|
begin
|
12
|
-
|
13
|
-
|
14
|
-
|
12
|
+
msg = JSON.parse(data)
|
13
|
+
msg.inject({}){|memo,(k,v)| memo[k.to_sym] = v; memo}
|
14
|
+
report(msg)
|
15
|
+
src.reply "sended\n"
|
15
16
|
rescue
|
16
17
|
log :error, "Failed to send message: #{data.inspect}"
|
17
18
|
src.reply "failed to send: #{data.inspect}\n"
|