chef-handler-datadog 0.6.0 → 0.7.0

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.
@@ -0,0 +1,204 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: https://app.datadoghq.com/api/v1/series?api_key=<API_KEY>
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"series":[{"metric":"chef.resources.total","points":[[1428248969,0.0]],"type":"gauge","host":"chef.handler.datadog.test-tags","device":null}]}'
9
+ headers:
10
+ Accept-Encoding:
11
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
12
+ Accept:
13
+ - "*/*"
14
+ User-Agent:
15
+ - Ruby
16
+ Content-Type:
17
+ - application/json
18
+ response:
19
+ status:
20
+ code: 202
21
+ message: Accepted
22
+ headers:
23
+ Content-Type:
24
+ - text/json; charset=UTF-8
25
+ Date:
26
+ - Sun, 05 Apr 2015 15:49:25 GMT
27
+ Server:
28
+ - dogdispatcher/6.1.23
29
+ Strict-Transport-Security:
30
+ - max-age=15724800;
31
+ Content-Length:
32
+ - '15'
33
+ Connection:
34
+ - keep-alive
35
+ body:
36
+ encoding: UTF-8
37
+ string: '{"status":"ok"}'
38
+ http_version:
39
+ recorded_at: Sun, 05 Apr 2015 15:49:29 GMT
40
+ - request:
41
+ method: post
42
+ uri: https://app.datadoghq.com/api/v1/series?api_key=<API_KEY>
43
+ body:
44
+ encoding: UTF-8
45
+ string: '{"series":[{"metric":"chef.resources.updated","points":[[1428248969,0.0]],"type":"gauge","host":"chef.handler.datadog.test-tags","device":null}]}'
46
+ headers:
47
+ Accept-Encoding:
48
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
49
+ Accept:
50
+ - "*/*"
51
+ User-Agent:
52
+ - Ruby
53
+ Content-Type:
54
+ - application/json
55
+ response:
56
+ status:
57
+ code: 202
58
+ message: Accepted
59
+ headers:
60
+ Content-Type:
61
+ - text/json; charset=UTF-8
62
+ Date:
63
+ - Sun, 05 Apr 2015 15:49:26 GMT
64
+ Server:
65
+ - dogdispatcher/6.1.23
66
+ Strict-Transport-Security:
67
+ - max-age=15724800;
68
+ Content-Length:
69
+ - '15'
70
+ Connection:
71
+ - keep-alive
72
+ body:
73
+ encoding: UTF-8
74
+ string: '{"status":"ok"}'
75
+ http_version:
76
+ recorded_at: Sun, 05 Apr 2015 15:49:29 GMT
77
+ - request:
78
+ method: post
79
+ uri: https://app.datadoghq.com/api/v1/series?api_key=<API_KEY>
80
+ body:
81
+ encoding: UTF-8
82
+ string: '{"series":[{"metric":"chef.resources.elapsed_time","points":[[1428248969,5.0]],"type":"gauge","host":"chef.handler.datadog.test-tags","device":null}]}'
83
+ headers:
84
+ Accept-Encoding:
85
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
86
+ Accept:
87
+ - "*/*"
88
+ User-Agent:
89
+ - Ruby
90
+ Content-Type:
91
+ - application/json
92
+ response:
93
+ status:
94
+ code: 202
95
+ message: Accepted
96
+ headers:
97
+ Content-Type:
98
+ - text/json; charset=UTF-8
99
+ Date:
100
+ - Sun, 05 Apr 2015 15:49:26 GMT
101
+ Server:
102
+ - dogdispatcher/6.1.23
103
+ Strict-Transport-Security:
104
+ - max-age=15724800;
105
+ Content-Length:
106
+ - '15'
107
+ Connection:
108
+ - keep-alive
109
+ body:
110
+ encoding: UTF-8
111
+ string: '{"status":"ok"}'
112
+ http_version:
113
+ recorded_at: Sun, 05 Apr 2015 15:49:29 GMT
114
+ - request:
115
+ method: post
116
+ uri: https://app.datadoghq.com/api/v1/events?api_key=<API_KEY>
117
+ body:
118
+ encoding: UTF-8
119
+ string: '{"msg_text":"Chef updated 0 resources out of 0 resources total.","date_happened":1428248969,"msg_title":"Chef
120
+ completed in 5 seconds on chef.handler.datadog.test-tags ","priority":"low","parent":null,"tags":["env:hostile","role:highlander"],"aggregation_key":"chef.handler.datadog.test-tags","alert_type":"success","event_type":"config_management.run","source_type_name":"chef","title":"Chef
121
+ completed in 5 seconds on chef.handler.datadog.test-tags ","text":"Chef updated
122
+ 0 resources out of 0 resources total.","host":"chef.handler.datadog.test-tags","device":null}'
123
+ headers:
124
+ Accept-Encoding:
125
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
126
+ Accept:
127
+ - "*/*"
128
+ User-Agent:
129
+ - Ruby
130
+ Content-Type:
131
+ - application/json
132
+ response:
133
+ status:
134
+ code: 202
135
+ message: Accepted
136
+ headers:
137
+ Content-Type:
138
+ - text/json; charset=UTF-8
139
+ Date:
140
+ - Sun, 05 Apr 2015 15:49:27 GMT
141
+ Server:
142
+ - dogdispatcher/6.1.23
143
+ Strict-Transport-Security:
144
+ - max-age=15724800;
145
+ Content-Length:
146
+ - '396'
147
+ Connection:
148
+ - keep-alive
149
+ body:
150
+ encoding: UTF-8
151
+ string: '{"status": "ok", "event": {"priority": "low", "date_happened": 1428248969,
152
+ "handle": null, "title": "Chef completed in 5 seconds on chef.handler.datadog.test-tags
153
+ ", "url": "https://app.datadoghq.com/event/event?id=2751230245696245756",
154
+ "text": "Chef updated 0 resources out of 0 resources total.", "tags": ["env:hostile",
155
+ "role:highlander"], "related_event_id": null, "id": 2751230245696245756}}'
156
+ http_version:
157
+ recorded_at: Sun, 05 Apr 2015 15:49:29 GMT
158
+ - request:
159
+ method: put
160
+ uri: https://app.datadoghq.com/api/v1/tags/hosts/chef.handler.datadog.test-tags?api_key=<API_KEY>&application_key=<APPLICATION_KEY>&source=chef
161
+ body:
162
+ encoding: UTF-8
163
+ string: '{"tags":["env:hostile","role:highlander"]}'
164
+ headers:
165
+ Accept-Encoding:
166
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
167
+ Accept:
168
+ - "*/*"
169
+ User-Agent:
170
+ - Ruby
171
+ Content-Type:
172
+ - application/json
173
+ response:
174
+ status:
175
+ code: 201
176
+ message: Created
177
+ headers:
178
+ Cache-Control:
179
+ - no-cache
180
+ Content-Type:
181
+ - application/json
182
+ Date:
183
+ - Sun, 05 Apr 2015 15:49:28 GMT
184
+ Pragma:
185
+ - no-cache
186
+ Server:
187
+ - gunicorn/19.1.0
188
+ Strict-Transport-Security:
189
+ - max-age=15724800;
190
+ X-Dd-Debug:
191
+ - K5UeadTtPqoFikPi1o+Wft0+9g+d2LCw4qfYk8mXP20=
192
+ X-Frame-Options:
193
+ - SAMEORIGIN
194
+ Content-Length:
195
+ - '86'
196
+ Connection:
197
+ - keep-alive
198
+ body:
199
+ encoding: UTF-8
200
+ string: '{"host": "chef.handler.datadog.test-tags", "tags": ["env:hostile",
201
+ "role:highlander"]}'
202
+ http_version:
203
+ recorded_at: Sun, 05 Apr 2015 15:49:29 GMT
204
+ recorded_with: VCR 2.9.3
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chef-handler-datadog
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 0.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Fiedler
@@ -10,166 +10,166 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2014-09-17 00:00:00.000000000 Z
13
+ date: 2015-10-22 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: dogapi
17
17
  requirement: !ruby/object:Gem::Requirement
18
18
  requirements:
19
- - - ! '>='
19
+ - - ">="
20
20
  - !ruby/object:Gem::Version
21
21
  version: '1.6'
22
22
  type: :runtime
23
23
  prerelease: false
24
24
  version_requirements: !ruby/object:Gem::Requirement
25
25
  requirements:
26
- - - ! '>='
26
+ - - ">="
27
27
  - !ruby/object:Gem::Version
28
28
  version: '1.6'
29
29
  - !ruby/object:Gem::Dependency
30
30
  name: appraisal
31
31
  requirement: !ruby/object:Gem::Requirement
32
32
  requirements:
33
- - - ~>
33
+ - - "~>"
34
34
  - !ruby/object:Gem::Version
35
- version: 1.0.0
35
+ version: 2.0.1
36
36
  type: :development
37
37
  prerelease: false
38
38
  version_requirements: !ruby/object:Gem::Requirement
39
39
  requirements:
40
- - - ~>
40
+ - - "~>"
41
41
  - !ruby/object:Gem::Version
42
- version: 1.0.0
42
+ version: 2.0.1
43
43
  - !ruby/object:Gem::Dependency
44
44
  name: bundler
45
45
  requirement: !ruby/object:Gem::Requirement
46
46
  requirements:
47
- - - ! '>='
47
+ - - ">="
48
48
  - !ruby/object:Gem::Version
49
49
  version: '0'
50
50
  type: :development
51
51
  prerelease: false
52
52
  version_requirements: !ruby/object:Gem::Requirement
53
53
  requirements:
54
- - - ! '>='
54
+ - - ">="
55
55
  - !ruby/object:Gem::Version
56
56
  version: '0'
57
57
  - !ruby/object:Gem::Dependency
58
58
  name: chef
59
59
  requirement: !ruby/object:Gem::Requirement
60
60
  requirements:
61
- - - ! '>='
61
+ - - ">="
62
62
  - !ruby/object:Gem::Version
63
- version: '10'
64
- - - <=
63
+ version: 10.14.4
64
+ - - "<="
65
65
  - !ruby/object:Gem::Version
66
- version: '12'
66
+ version: '13'
67
67
  type: :development
68
68
  prerelease: false
69
69
  version_requirements: !ruby/object:Gem::Requirement
70
70
  requirements:
71
- - - ! '>='
71
+ - - ">="
72
72
  - !ruby/object:Gem::Version
73
- version: '10'
74
- - - <=
73
+ version: 10.14.4
74
+ - - "<="
75
75
  - !ruby/object:Gem::Version
76
- version: '12'
76
+ version: '13'
77
77
  - !ruby/object:Gem::Dependency
78
78
  name: dotenv
79
79
  requirement: !ruby/object:Gem::Requirement
80
80
  requirements:
81
- - - ! '>='
81
+ - - ">="
82
82
  - !ruby/object:Gem::Version
83
83
  version: '0'
84
84
  type: :development
85
85
  prerelease: false
86
86
  version_requirements: !ruby/object:Gem::Requirement
87
87
  requirements:
88
- - - ! '>='
88
+ - - ">="
89
89
  - !ruby/object:Gem::Version
90
90
  version: '0'
91
91
  - !ruby/object:Gem::Dependency
92
92
  name: rake
93
93
  requirement: !ruby/object:Gem::Requirement
94
94
  requirements:
95
- - - ! '>='
95
+ - - ">="
96
96
  - !ruby/object:Gem::Version
97
97
  version: '0'
98
98
  type: :development
99
99
  prerelease: false
100
100
  version_requirements: !ruby/object:Gem::Requirement
101
101
  requirements:
102
- - - ! '>='
102
+ - - ">="
103
103
  - !ruby/object:Gem::Version
104
104
  version: '0'
105
105
  - !ruby/object:Gem::Dependency
106
106
  name: rspec
107
107
  requirement: !ruby/object:Gem::Requirement
108
108
  requirements:
109
- - - ~>
109
+ - - "~>"
110
110
  - !ruby/object:Gem::Version
111
- version: 3.0.0
111
+ version: 3.2.0
112
112
  type: :development
113
113
  prerelease: false
114
114
  version_requirements: !ruby/object:Gem::Requirement
115
115
  requirements:
116
- - - ~>
116
+ - - "~>"
117
117
  - !ruby/object:Gem::Version
118
- version: 3.0.0
118
+ version: 3.2.0
119
119
  - !ruby/object:Gem::Dependency
120
120
  name: rubocop
121
121
  requirement: !ruby/object:Gem::Requirement
122
122
  requirements:
123
- - - ~>
123
+ - - "~>"
124
124
  - !ruby/object:Gem::Version
125
- version: 0.25.0
125
+ version: 0.34.2
126
126
  type: :development
127
127
  prerelease: false
128
128
  version_requirements: !ruby/object:Gem::Requirement
129
129
  requirements:
130
- - - ~>
130
+ - - "~>"
131
131
  - !ruby/object:Gem::Version
132
- version: 0.25.0
132
+ version: 0.34.2
133
133
  - !ruby/object:Gem::Dependency
134
134
  name: simplecov
135
135
  requirement: !ruby/object:Gem::Requirement
136
136
  requirements:
137
- - - ! '>='
137
+ - - ">="
138
138
  - !ruby/object:Gem::Version
139
139
  version: '0'
140
140
  type: :development
141
141
  prerelease: false
142
142
  version_requirements: !ruby/object:Gem::Requirement
143
143
  requirements:
144
- - - ! '>='
144
+ - - ">="
145
145
  - !ruby/object:Gem::Version
146
146
  version: '0'
147
147
  - !ruby/object:Gem::Dependency
148
148
  name: vcr
149
149
  requirement: !ruby/object:Gem::Requirement
150
150
  requirements:
151
- - - ! '>='
151
+ - - ">="
152
152
  - !ruby/object:Gem::Version
153
153
  version: '0'
154
154
  type: :development
155
155
  prerelease: false
156
156
  version_requirements: !ruby/object:Gem::Requirement
157
157
  requirements:
158
- - - ! '>='
158
+ - - ">="
159
159
  - !ruby/object:Gem::Version
160
160
  version: '0'
161
161
  - !ruby/object:Gem::Dependency
162
162
  name: webmock
163
163
  requirement: !ruby/object:Gem::Requirement
164
164
  requirements:
165
- - - ! '>='
165
+ - - ">="
166
166
  - !ruby/object:Gem::Version
167
167
  version: '0'
168
168
  type: :development
169
169
  prerelease: false
170
170
  version_requirements: !ruby/object:Gem::Requirement
171
171
  requirements:
172
- - - ! '>='
172
+ - - ">="
173
173
  - !ruby/object:Gem::Version
174
174
  version: '0'
175
175
  description: This Handler will report the events and metrics for a chef-client run
@@ -182,10 +182,10 @@ extra_rdoc_files:
182
182
  - README.md
183
183
  - LICENSE.txt
184
184
  files:
185
- - .gitignore
186
- - .rspec
187
- - .rubocop.yml
188
- - .travis.yml
185
+ - ".gitignore"
186
+ - ".rspec"
187
+ - ".rubocop.yml"
188
+ - ".travis.yml"
189
189
  - Appraisals
190
190
  - CHANGELOG.md
191
191
  - CONTRIBUTING.md
@@ -195,15 +195,14 @@ files:
195
195
  - README.md
196
196
  - Rakefile
197
197
  - chef-handler-datadog.gemspec
198
- - gemfiles/chef_10.26.0.gemfile
199
- - gemfiles/chef_10.32.2.gemfile
200
- - gemfiles/chef_11.10.4.gemfile
201
- - gemfiles/chef_11.12.8.gemfile
202
- - gemfiles/chef_11.14.2.gemfile
203
- - gemfiles/chef_11.16.0.gemfile
204
- - gemfiles/chef_11.8.2.gemfile
205
- - gemfiles/chef_12.0.0.alpha.1.gemfile
198
+ - gemfiles/chef_10.14.4.gemfile
199
+ - gemfiles/chef_10.gemfile
200
+ - gemfiles/chef_11.gemfile
201
+ - gemfiles/chef_12.gemfile
206
202
  - lib/chef/handler/datadog.rb
203
+ - lib/chef/handler/datadog_chef_events.rb
204
+ - lib/chef/handler/datadog_chef_metrics.rb
205
+ - lib/chef/handler/datadog_chef_tags.rb
207
206
  - lib/chef_handler_datadog.rb
208
207
  - spec/datadog_spec.rb
209
208
  - spec/spec_helper.rb
@@ -211,7 +210,6 @@ files:
211
210
  - spec/support/cassettes/Chef_Handler_Datadog/failed_Chef_run/sets_event_title_correctly.yml
212
211
  - spec/support/cassettes/Chef_Handler_Datadog/failed_Chef_run/sets_priority_correctly.yml
213
212
  - spec/support/cassettes/Chef_Handler_Datadog/handles_no_application_key/fails_when_no_application_key_is_provided.yml
214
- - spec/support/cassettes/Chef_Handler_Datadog/handles_tags_correctly/sets_the_role_and_env_and_tags.yml
215
213
  - spec/support/cassettes/Chef_Handler_Datadog/hostname/uses_the_node_name_when_no_config_specified.yml
216
214
  - spec/support/cassettes/Chef_Handler_Datadog/hostname/uses_the_specified_hostname_when_provided.yml
217
215
  - spec/support/cassettes/Chef_Handler_Datadog/reports_correct_hostname_on_an_ec2_node/does_not_use_the_instance_id_when_config_specified_to_false.yml
@@ -223,6 +221,8 @@ files:
223
221
  - spec/support/cassettes/Chef_Handler_Datadog/reports_metrics_event_and_sets_tags/sets_tags/puts_the_tags_for_the_current_node.yml
224
222
  - spec/support/cassettes/Chef_Handler_Datadog/resources/failure_during_compile_phase/does_not_emit_metrics.yml
225
223
  - spec/support/cassettes/Chef_Handler_Datadog/resources/failure_during_compile_phase/posts_an_event.yml
224
+ - spec/support/cassettes/Chef_Handler_Datadog/tags/when_specified/sets_the_role_and_env_and_tags.yml
225
+ - spec/support/cassettes/Chef_Handler_Datadog/tags/when_unspecified/sets_role_env_and_nothing_else.yml
226
226
  - spec/support/cassettes/Chef_Handler_Datadog/updated_resources/posts_an_event.yml
227
227
  homepage: http://www.datadoghq.com/
228
228
  licenses:
@@ -234,17 +234,17 @@ require_paths:
234
234
  - lib
235
235
  required_ruby_version: !ruby/object:Gem::Requirement
236
236
  requirements:
237
- - - ! '>='
237
+ - - ">="
238
238
  - !ruby/object:Gem::Version
239
239
  version: '0'
240
240
  required_rubygems_version: !ruby/object:Gem::Requirement
241
241
  requirements:
242
- - - ! '>='
242
+ - - ">="
243
243
  - !ruby/object:Gem::Version
244
244
  version: '0'
245
245
  requirements: []
246
246
  rubyforge_project:
247
- rubygems_version: 2.2.2
247
+ rubygems_version: 2.4.3
248
248
  signing_key:
249
249
  specification_version: 4
250
250
  summary: Chef Handler reports events and metrics to Datadog
@@ -255,7 +255,6 @@ test_files:
255
255
  - spec/support/cassettes/Chef_Handler_Datadog/failed_Chef_run/sets_event_title_correctly.yml
256
256
  - spec/support/cassettes/Chef_Handler_Datadog/failed_Chef_run/sets_priority_correctly.yml
257
257
  - spec/support/cassettes/Chef_Handler_Datadog/handles_no_application_key/fails_when_no_application_key_is_provided.yml
258
- - spec/support/cassettes/Chef_Handler_Datadog/handles_tags_correctly/sets_the_role_and_env_and_tags.yml
259
258
  - spec/support/cassettes/Chef_Handler_Datadog/hostname/uses_the_node_name_when_no_config_specified.yml
260
259
  - spec/support/cassettes/Chef_Handler_Datadog/hostname/uses_the_specified_hostname_when_provided.yml
261
260
  - spec/support/cassettes/Chef_Handler_Datadog/reports_correct_hostname_on_an_ec2_node/does_not_use_the_instance_id_when_config_specified_to_false.yml
@@ -267,4 +266,6 @@ test_files:
267
266
  - spec/support/cassettes/Chef_Handler_Datadog/reports_metrics_event_and_sets_tags/sets_tags/puts_the_tags_for_the_current_node.yml
268
267
  - spec/support/cassettes/Chef_Handler_Datadog/resources/failure_during_compile_phase/does_not_emit_metrics.yml
269
268
  - spec/support/cassettes/Chef_Handler_Datadog/resources/failure_during_compile_phase/posts_an_event.yml
269
+ - spec/support/cassettes/Chef_Handler_Datadog/tags/when_specified/sets_the_role_and_env_and_tags.yml
270
+ - spec/support/cassettes/Chef_Handler_Datadog/tags/when_unspecified/sets_role_env_and_nothing_else.yml
270
271
  - spec/support/cassettes/Chef_Handler_Datadog/updated_resources/posts_an_event.yml