bipbip 0.7.5 → 0.7.6
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/lib/bipbip/agent.rb +7 -1
- data/lib/bipbip/storage/copperegg.rb +4 -14
- data/lib/bipbip/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 16fdb7060fac95aa36861da6c0ef00e2cf93ea8a
|
4
|
+
data.tar.gz: b83c498c93518cf3e00c213f83adc802c32cf065
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b8c7e298b384f8073141186e410e998e4729ab8f06c0e7b97b8970b854fdf41ba169033c57ea5ca9e15941e2bbe49d43a7c73bbc9143a91cd0646101807074e6
|
7
|
+
data.tar.gz: ddc205d79f1aa89fc6009fb3131687a41a6e11dde8476b6273bd81fb8fb1951c43059cc75864a7cea7dcdb1290274d4b7e01aa0e3a0c238bc669b28edb04a90e
|
data/lib/bipbip/agent.rb
CHANGED
@@ -26,7 +26,13 @@ module Bipbip
|
|
26
26
|
@storages.each do |storage|
|
27
27
|
@plugins.each do |plugin|
|
28
28
|
Bipbip.logger.info "Setting up plugin #{plugin.name} for storage #{storage.name}"
|
29
|
-
|
29
|
+
begin
|
30
|
+
storage.setup_plugin(plugin)
|
31
|
+
rescue => e
|
32
|
+
Bipbip.logger.fatal "Failed to setup plugin #{plugin.name} for storage #{storage.name}: `#{e.message}`. Retrying..."
|
33
|
+
sleep 5
|
34
|
+
retry
|
35
|
+
end
|
30
36
|
end
|
31
37
|
end
|
32
38
|
|
@@ -11,8 +11,7 @@ module Bipbip
|
|
11
11
|
@tags ||= _load_tags
|
12
12
|
|
13
13
|
unless [5, 15, 60, 300, 900, 3600, 21_600].include?(plugin.frequency)
|
14
|
-
|
15
|
-
exit 1
|
14
|
+
raise "Cannot use frequency #{plugin.frequency}"
|
16
15
|
end
|
17
16
|
|
18
17
|
metric_group = @metric_groups.detect { |m| m.name == plugin.metric_group }
|
@@ -65,20 +64,14 @@ module Bipbip
|
|
65
64
|
def _load_metric_groups
|
66
65
|
log(Logger::INFO, 'Loading metric groups')
|
67
66
|
metric_groups = ::Copperegg::Revealmetrics::MetricGroup.find
|
68
|
-
if metric_groups.nil?
|
69
|
-
log(Logger::FATAL, 'Cannot load metric groups')
|
70
|
-
exit 1
|
71
|
-
end
|
67
|
+
raise 'Cannot load metric groups' if metric_groups.nil?
|
72
68
|
metric_groups
|
73
69
|
end
|
74
70
|
|
75
71
|
def _load_dashboards
|
76
72
|
log(Logger::INFO, 'Loading dashboards')
|
77
73
|
dashboards = ::Copperegg::Revealmetrics::CustomDashboard.find
|
78
|
-
if dashboards.nil?
|
79
|
-
log(Logger::FATAL, 'Cannot load dashboards')
|
80
|
-
exit 1
|
81
|
-
end
|
74
|
+
raise 'Cannot load dashboards' if dashboards.nil?
|
82
75
|
dashboards
|
83
76
|
end
|
84
77
|
|
@@ -86,10 +79,7 @@ module Bipbip
|
|
86
79
|
def _load_tags
|
87
80
|
log(Logger::INFO, 'Loading tags')
|
88
81
|
tags = ::Copperegg::Revealmetrics::Tag.find
|
89
|
-
if tags.nil?
|
90
|
-
log(Logger::FATAL, 'Cannot load tags')
|
91
|
-
exit 1
|
92
|
-
end
|
82
|
+
raise 'Cannot load tags' if tags.nil?
|
93
83
|
tags
|
94
84
|
end
|
95
85
|
end
|
data/lib/bipbip/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bipbip
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Cargo Media
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2016-10-
|
13
|
+
date: 2016-10-12 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: copperegg-revealmetrics
|