seismograph 0.3.2 → 0.3.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/seismograph/sensor.rb +4 -2
- data/lib/seismograph/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 304fac66cef6e2f2769cc51ea065b2bba6951c9b
|
4
|
+
data.tar.gz: 90d0508529ca3bc5c677a2ff83f5fc271af82879
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b9af1485de248004538db1b27091621538d0599894022210d4c92440eb9be65895d6cdf7ae431b98569240900146c795c0481c5b21c89d31ca3698bca48abd7a
|
7
|
+
data.tar.gz: 12e55c9351e94d1c5d3e37a902d17c46b085a548e56d231d35976844bff004cdf75742509cee2065553280afe456f98752492284dca80543dbf262ffa538753b
|
data/lib/seismograph/sensor.rb
CHANGED
@@ -43,14 +43,16 @@ module Seismograph
|
|
43
43
|
|
44
44
|
def track(description, amount, params = {})
|
45
45
|
with_success_and_failure(description, params) do
|
46
|
-
yield if block_given?
|
46
|
+
result = yield if block_given?
|
47
47
|
Gateway.histogram(stat(description), amount, gateway_params(params))
|
48
|
+
result
|
48
49
|
end
|
49
50
|
end
|
50
51
|
|
51
52
|
def with_success_and_failure(description, params)
|
52
|
-
yield
|
53
|
+
result = yield
|
53
54
|
increment("#{description}.success", gateway_params(params))
|
55
|
+
result
|
54
56
|
rescue StandardError => e
|
55
57
|
increment("#{description}.failure", gateway_params(params))
|
56
58
|
raise e
|
data/lib/seismograph/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: seismograph
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brandon Croft
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2016-
|
12
|
+
date: 2016-03-15 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: dogstatsd-ruby
|
@@ -138,7 +138,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
138
138
|
version: '0'
|
139
139
|
requirements: []
|
140
140
|
rubyforge_project:
|
141
|
-
rubygems_version: 2.
|
141
|
+
rubygems_version: 2.5.1
|
142
142
|
signing_key:
|
143
143
|
specification_version: 4
|
144
144
|
summary: Helper library to report stats and events to datadoghq
|