meter 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/meter.rb +4 -0
- data/lib/meter/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: a16b383b11cd7e6a9ae94e8d45cf5406c2abc239
|
4
|
+
data.tar.gz: 9c26ee9e5f0b694cc5e3d4802a1c2786ec8ce462
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0fb0bc199b24c1d559b7514ccb6bea571dc46c36e62748953cbb969968ad399e5adfa4c7e651162c6e14990f0cd391c087828fe22ccaf31d0f9c8987c7a8239d
|
7
|
+
data.tar.gz: 67b15fc4562ecd74ec4995ccdd10e95ce1630a8feb524dedd03dc4383945cc8c4e6dd0380f1558c4dff522237a2947e1cdcd51544de8f27628b75d219cdcc1ba
|
data/lib/meter.rb
CHANGED
@@ -24,6 +24,10 @@ module Meter
|
|
24
24
|
end
|
25
25
|
alias :track :increment
|
26
26
|
|
27
|
+
def log(key, log_data = {})
|
28
|
+
track key, data: log_data
|
29
|
+
end
|
30
|
+
|
27
31
|
def gauge(key, value, sample_rate: 1, tags: {}, data: {})
|
28
32
|
metric = Metric::Gauge.new(name: key, value: value, sample_rate: sample_rate, tags: tags, data: data)
|
29
33
|
send_metric_to_backends(metric)
|
data/lib/meter/version.rb
CHANGED