fluent-plugin-dd 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- Mzg2ZDBiZmE5YmNmOGQzNzcyYTAzMjUxMGU3YmZmMmVmMmM1Mzk2OA==
4
+ ODg3YzliYmQ2NTdjOWRjMDU1MTg0NDZmOWVmMzZlNDRkM2M0YmE4ZA==
5
5
  data.tar.gz: !binary |-
6
- YWVkNzllMDY0NmZhYTc2NjI1ZjU2MjE5MjZhMzQxODQ0NjlmYWQxMw==
6
+ MTY0NzExYzM2ZWM1YjBkNjVjOGJkZmU3MmZmYjE0ZjAwMzhiMTkzYQ==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- MDRkY2M3NTdiMWVhMmM0OGUyYjRhNGE3YjM2ZGIzZTFiNTUxZmIyNDlhOTM5
10
- OWNjNDQ0M2I5ZjUzODE2MTE4YTkwMDNjNGQ1OTBkY2ExOTQ2MDExZDM3OTAw
11
- ZWVkNTc5ODk2OWNkMmU2YzRjMWJjZjU4MDM0ZTU0ZDIyMmQyNGM=
9
+ ZDAyMWU5Mzk5YTA0YmQwNTBmYTNlMDQxMzU4YTBhZDhkOTNkYWIzZTU5NjQy
10
+ M2EwYWQ0YWRmMjViMDM5MWY1MGNiZGM4ZjcwOTgyYjlmMGI1YmQ3YjAxYzE5
11
+ MzU5NmU0YWJlNDQ2MjVhOTQ0OGE3Mzc0YmQzMGRhYjc3NGZjNzY=
12
12
  data.tar.gz: !binary |-
13
- ZGMzM2M4MmZmNjhjODI1ZmViNmI2YjJhMDJjZDgzYzIwMDhlNmJiMWVmMWQy
14
- NTJhYTRhZGExYjU2NzhkYjhhZDljNWI2Y2E2MTc4OTFjOGM2YzNmMDY2NzBi
15
- ZGVjYTQ2ZjQ5YzEyMGViOThhZTcyZDNlNjQwMTU4MGJkMGI1N2E=
13
+ OGM0ZTJmZDYzNjEwNWYwZjQ5ODA2YjUyZjU0ZTkzNGNjODRmYWRmYzk3MGE5
14
+ NjlkMDg5NjlkNzdmOGEwZjViNTg1MWQxYzExMWQxNDBiZGYyOTFhZmY0Mzc4
15
+ Zjk5OGJhYzQwMTA4MjUxOGYzNTVkOTljOTBiY2E5MmY1NDZkYzg=
@@ -1,7 +1,7 @@
1
1
  # coding: utf-8
2
2
  Gem::Specification.new do |spec|
3
3
  spec.name = 'fluent-plugin-dd'
4
- spec.version = '0.1.1'
4
+ spec.version = '0.1.2'
5
5
  spec.authors = ['Genki Sugawara']
6
6
  spec.email = ['sugawara@cookpad.com']
7
7
  spec.description = %q{Output plugin for Datadog}
@@ -63,9 +63,9 @@ class Fluent::DdOutput < Fluent::BufferedOutput
63
63
  end
64
64
 
65
65
  options = {}
66
- options['tags'] = tag.split(',').map {|i| i.strip } if tag
67
- options['host'] = host if host
68
- options['type'] = type if type
66
+ options[:tags] = tag.split(',').map {|i| i.strip } if tag
67
+ options[:host] = host if host
68
+ options[:type] = type if type
69
69
 
70
70
  @dog.emit_points(metric, points, options)
71
71
  }
data/spec/out_dd_spec.rb CHANGED
@@ -14,7 +14,7 @@ describe Fluent::DdOutput do
14
14
  "some.metric.name",
15
15
  [[Time.parse("2014-02-08 04:14:15 UTC"), 50.0],
16
16
  [Time.parse("2014-02-08 04:14:15 UTC"), 100.0]],
17
- {"tags"=>["test.default"]}
17
+ {:tags=>["test.default"]}
18
18
  )
19
19
 
20
20
  d.emit({"metric" => "some.metric.name", "value" => 50.0}, time)
@@ -28,21 +28,21 @@ describe Fluent::DdOutput do
28
28
  "some.metric.name",
29
29
  [[Time.parse("2014-02-08 04:14:15 UTC"), 50.0],
30
30
  [Time.parse("2014-02-08 04:14:15 UTC"), 100.0]],
31
- {"tags"=>["test.1"]}
31
+ {:tags=>["test.1"]}
32
32
  )
33
33
 
34
34
  dog.should_receive(:emit_points).with(
35
35
  "some.metric.name",
36
36
  [[Time.parse("2014-02-08 04:14:15 UTC"), 150.0],
37
37
  [Time.parse("2014-02-08 04:14:15 UTC"), 200.0]],
38
- {"tags"=>["test.2"]}
38
+ {:tags=>["test.2"]}
39
39
  )
40
40
 
41
41
  dog.should_receive(:emit_points).with(
42
42
  "some.metric.name",
43
43
  [[Time.parse("2014-02-08 04:14:15 UTC"), 250.0],
44
44
  [Time.parse("2014-02-08 04:14:15 UTC"), 300.0]],
45
- {"tags"=>["test.3"]}
45
+ {:tags=>["test.3"]}
46
46
  )
47
47
 
48
48
  d.tag = 'test.1'
@@ -65,21 +65,21 @@ describe Fluent::DdOutput do
65
65
  "some.metric.name",
66
66
  [[Time.parse("2014-02-08 04:14:15 UTC"), 50.0],
67
67
  [Time.parse("2014-02-08 04:14:15 UTC"), 100.0]],
68
- {"tags"=>["test.11"]}
68
+ {:tags=>["test.11"]}
69
69
  )
70
70
 
71
71
  dog.should_receive(:emit_points).with(
72
72
  "some.metric.name",
73
73
  [[Time.parse("2014-02-08 04:14:15 UTC"), 150.0],
74
74
  [Time.parse("2014-02-08 04:14:15 UTC"), 200.0]],
75
- {"tags"=>["test.21"]}
75
+ {:tags=>["test.21"]}
76
76
  )
77
77
 
78
78
  dog.should_receive(:emit_points).with(
79
79
  "some.metric.name",
80
80
  [[Time.parse("2014-02-08 04:14:15 UTC"), 250.0],
81
81
  [Time.parse("2014-02-08 04:14:15 UTC"), 300.0]],
82
- {"tags"=>["test.31"]}
82
+ {:tags=>["test.31"]}
83
83
  )
84
84
 
85
85
  d.emit({"metric" => "some.metric.name", "value" => 50.0, "tag" => "test.11"}, time)
@@ -99,21 +99,21 @@ describe Fluent::DdOutput do
99
99
  "some.metric.name",
100
100
  [[Time.parse("2014-02-08 04:14:15 UTC"), 50.0],
101
101
  [Time.parse("2014-02-08 04:14:15 UTC"), 100.0]],
102
- {"tags"=>["test.12","test.13"]}
102
+ {:tags=>["test.12","test.13"]}
103
103
  )
104
104
 
105
105
  dog.should_receive(:emit_points).with(
106
106
  "some.metric.name",
107
107
  [[Time.parse("2014-02-08 04:14:15 UTC"), 150.0],
108
108
  [Time.parse("2014-02-08 04:14:15 UTC"), 200.0]],
109
- {"tags"=>["test.22","test.23"]}
109
+ {:tags=>["test.22","test.23"]}
110
110
  )
111
111
 
112
112
  dog.should_receive(:emit_points).with(
113
113
  "some.metric.name",
114
114
  [[Time.parse("2014-02-08 04:14:15 UTC"), 250.0],
115
115
  [Time.parse("2014-02-08 04:14:15 UTC"), 300.0]],
116
- {"tags"=>["test.32","test.33"]}
116
+ {:tags=>["test.32","test.33"]}
117
117
  )
118
118
 
119
119
  d.emit({"metric" => "some.metric.name", "value" => 50.0, "tag" => "test.12,test.13"}, time)
@@ -133,21 +133,21 @@ describe Fluent::DdOutput do
133
133
  "some.metric.name",
134
134
  [[Time.parse("2014-02-08 04:14:15 UTC"), 50.0],
135
135
  [Time.parse("2014-02-08 04:14:15 UTC"), 100.0]],
136
- {"tags"=>["test.default"], "host"=>"www1.example.com"}
136
+ {:tags=>["test.default"], :host=>"www1.example.com"}
137
137
  )
138
138
 
139
139
  dog.should_receive(:emit_points).with(
140
140
  "some.metric.name",
141
141
  [[Time.parse("2014-02-08 04:14:15 UTC"), 150.0],
142
142
  [Time.parse("2014-02-08 04:14:15 UTC"), 200.0]],
143
- {"tags"=>["test.default"], "host"=>"www2.example.com"}
143
+ {:tags=>["test.default"], :host=>"www2.example.com"}
144
144
  )
145
145
 
146
146
  dog.should_receive(:emit_points).with(
147
147
  "some.metric.name",
148
148
  [[Time.parse("2014-02-08 04:14:15 UTC"), 250.0],
149
149
  [Time.parse("2014-02-08 04:14:15 UTC"), 300.0]],
150
- {"tags"=>["test.default"], "host"=>"www3.example.com"}
150
+ {:tags=>["test.default"], :host=>"www3.example.com"}
151
151
  )
152
152
 
153
153
  d.emit({"metric" => "some.metric.name", "value" => 50.0, "host" => "www1.example.com"}, time)
@@ -165,14 +165,14 @@ describe Fluent::DdOutput do
165
165
  "some.metric.name",
166
166
  [[Time.parse("2014-02-08 04:14:15 UTC"), 50.0],
167
167
  [Time.parse("2014-02-08 04:14:15 UTC"), 100.0]],
168
- {"tags"=>["test.default"], "type"=>"gauge"}
168
+ {:tags=>["test.default"], :type=>"gauge"}
169
169
  )
170
170
 
171
171
  dog.should_receive(:emit_points).with(
172
172
  "some.metric.name",
173
173
  [[Time.parse("2014-02-08 04:14:15 UTC"), 150.0],
174
174
  [Time.parse("2014-02-08 04:14:15 UTC"), 200.0]],
175
- {"tags"=>["test.default"], "type"=>"counter"}
175
+ {:tags=>["test.default"], :type=>"counter"}
176
176
  )
177
177
 
178
178
  d.emit({"metric" => "some.metric.name", "value" => 50.0, "type" => "gauge"}, time)
@@ -188,7 +188,7 @@ describe Fluent::DdOutput do
188
188
  "some.metric.name",
189
189
  [[Time.parse("2014-02-08 04:14:15 UTC"), 50.0],
190
190
  [Time.parse("2014-02-08 04:14:15 UTC"), 100.0]],
191
- {"tags"=>["test.default"]}
191
+ {:tags=>["test.default"]}
192
192
  )
193
193
 
194
194
  log = d.instance.log
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-dd
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Genki Sugawara