logstash-output-datadog_logs 0.5.0 → 0.5.3
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/CHANGELOG.md +10 -0
- data/Gemfile +9 -0
- data/README.md +6 -5
- data/lib/logstash/outputs/datadog_logs.rb +61 -16
- data/lib/logstash/outputs/version.rb +2 -2
- data/logstash-output-datadog_logs.gemspec +14 -5
- data/spec/outputs/datadog_logs_spec.rb +12 -11
- metadata +46 -17
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 35f5ce024bffbeaea8a434b00d7aa2e5c1bb2ce2a439bb69dd6f73dd7b92e269
|
4
|
+
data.tar.gz: f5565d500266000af583f7b647e3d33255e64dc8260a7c3d11ce7cb7ed3c2a5d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7e3503a6f977e30d581f964825f78348278533007084cbf584c05f8be6f8806c02dd43e5b32b8f7fc1cb9ba4ba47a66f884a95521e46d363e13495c4358e556f
|
7
|
+
data.tar.gz: 27f9fb1522429578e3bcb05575feddb90cf21343de8329d5fe151e25311d0bd91f8a85cac1bae3e4a7cb23429a10dbf735dd3d15321d9ff04bc943311ae98fca
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,13 @@
|
|
1
|
+
## 0.5.3
|
2
|
+
- Now is threadsafe: supports shared concurrency.
|
3
|
+
- Increase `DD_MAX_BATCH_LENGTH` to `1000`
|
4
|
+
|
5
|
+
## 0.5.2
|
6
|
+
- Now checks if logstash is being shutdown
|
7
|
+
|
8
|
+
## 0.5.1
|
9
|
+
- Support using HTTP proxies, adding the `http_proxy` parameter.
|
10
|
+
|
1
11
|
## 0.5.0
|
2
12
|
- Support Datadog v2 endpoints #28
|
3
13
|
|
data/Gemfile
CHANGED
@@ -1,2 +1,11 @@
|
|
1
1
|
source 'https://rubygems.org'
|
2
|
+
|
2
3
|
gemspec
|
4
|
+
|
5
|
+
logstash_path = ENV["LOGSTASH_PATH"] || "../../logstash"
|
6
|
+
use_logstash_source = ENV["LOGSTASH_SOURCE"] && ENV["LOGSTASH_SOURCE"].to_s == "1"
|
7
|
+
|
8
|
+
if Dir.exist?(logstash_path) && use_logstash_source
|
9
|
+
gem 'logstash-core', :path => "#{logstash_path}/logstash-core"
|
10
|
+
gem 'logstash-core-plugin-api', :path => "#{logstash_path}/logstash-core-plugin-api"
|
11
|
+
end
|
data/README.md
CHANGED
@@ -5,7 +5,7 @@ DatadogLogs lets you send logs to Datadog based on LogStash events.
|
|
5
5
|
|
6
6
|
## Requirements
|
7
7
|
|
8
|
-
The plugin relies upon the `zlib` library for compressing data.
|
8
|
+
The plugin relies upon the `zlib` library for compressing data. Successfully tested with Logstash 6.x, 7.x and 8.x.
|
9
9
|
|
10
10
|
## How to install it?
|
11
11
|
|
@@ -35,8 +35,8 @@ To enable TCP forwarding, configure your forwarder with:
|
|
35
35
|
output {
|
36
36
|
datadog_logs {
|
37
37
|
api_key => "<DATADOG_API_KEY>"
|
38
|
-
host => "
|
39
|
-
port =>
|
38
|
+
host => "intake.logs.datadoghq.com"
|
39
|
+
port => 443
|
40
40
|
use_http => false
|
41
41
|
}
|
42
42
|
}
|
@@ -58,8 +58,8 @@ output {
|
|
58
58
|
| Property | Description | Default value |
|
59
59
|
|-------------|--------------------------------------------------------------------------|----------------|
|
60
60
|
| **api_key** | The API key of your Datadog platform | nil |
|
61
|
-
| **host** |
|
62
|
-
| **port** |
|
61
|
+
| **host** | Endpoint when logs are not directly forwarded to Datadog | intake.logs.datadoghq.com |
|
62
|
+
| **port** | Port when logs are not directly forwarded to Datadog | 443 |
|
63
63
|
| **use_ssl** | If true, the agent initializes a secure connection to Datadog. Ensure to update the port if you disable it. | true |
|
64
64
|
| **max_retries** | The number of retries before the output plugin stops | 5 |
|
65
65
|
| **max_backoff** | The maximum time waited between each retry in seconds | 30 |
|
@@ -67,6 +67,7 @@ output {
|
|
67
67
|
| **use_compression** | Enable log compression for HTTP | true |
|
68
68
|
| **compression_level** | Set the log compression level for HTTP (1 to 9, 9 being the best ratio) | 6 |
|
69
69
|
| **no_ssl_validation** | Disable SSL validation (useful for proxy forwarding) | false |
|
70
|
+
| **http_proxy** | Proxy address for http proxies | none |
|
70
71
|
|
71
72
|
|
72
73
|
|
@@ -14,13 +14,15 @@ require_relative "version"
|
|
14
14
|
# based on LogStash events.
|
15
15
|
class LogStash::Outputs::DatadogLogs < LogStash::Outputs::Base
|
16
16
|
|
17
|
-
# Respect limit documented at https://docs.datadoghq.com/api
|
18
|
-
DD_MAX_BATCH_LENGTH =
|
17
|
+
# Respect limit documented at https://docs.datadoghq.com/api/latest/logs/#send-logs
|
18
|
+
DD_MAX_BATCH_LENGTH = 1000
|
19
19
|
DD_MAX_BATCH_SIZE = 5000000
|
20
20
|
DD_TRUNCATION_SUFFIX = "...TRUNCATED..."
|
21
21
|
|
22
22
|
config_name "datadog_logs"
|
23
23
|
|
24
|
+
concurrency :shared
|
25
|
+
|
24
26
|
default :codec, "json"
|
25
27
|
|
26
28
|
# Datadog configuration parameters
|
@@ -35,11 +37,12 @@ class LogStash::Outputs::DatadogLogs < LogStash::Outputs::Base
|
|
35
37
|
config :compression_level, :validate => :number, :required => false, :default => 6
|
36
38
|
config :no_ssl_validation, :validate => :boolean, :required => false, :default => false
|
37
39
|
config :force_v1_routes, :validate => :boolean, :required => false, :default => false # force using deprecated v1 routes
|
40
|
+
config :http_proxy, :validate => :string, :required => false, :default => ""
|
38
41
|
|
39
42
|
# Register the plugin to logstash
|
40
43
|
public
|
41
44
|
def register
|
42
|
-
@client = new_client(@logger, @api_key, @use_http, @use_ssl, @no_ssl_validation, @host, @port, @use_compression, @force_v1_routes)
|
45
|
+
@client = new_client(@logger, @api_key, @use_http, @use_ssl, @no_ssl_validation, @host, @port, @use_compression, @force_v1_routes, @http_proxy)
|
43
46
|
end
|
44
47
|
|
45
48
|
# Logstash shutdown hook
|
@@ -64,7 +67,11 @@ class LogStash::Outputs::DatadogLogs < LogStash::Outputs::Base
|
|
64
67
|
end
|
65
68
|
end
|
66
69
|
rescue => e
|
67
|
-
|
70
|
+
if e.is_a?(InterruptedError)
|
71
|
+
raise e
|
72
|
+
else
|
73
|
+
@logger.error("Uncaught processing exception in datadog forwarder #{e.message}")
|
74
|
+
end
|
68
75
|
end
|
69
76
|
end
|
70
77
|
|
@@ -145,9 +152,9 @@ class LogStash::Outputs::DatadogLogs < LogStash::Outputs::Base
|
|
145
152
|
end
|
146
153
|
|
147
154
|
# Build a new transport client
|
148
|
-
def new_client(logger, api_key, use_http, use_ssl, no_ssl_validation, host, port, use_compression, force_v1_routes)
|
155
|
+
def new_client(logger, api_key, use_http, use_ssl, no_ssl_validation, host, port, use_compression, force_v1_routes, http_proxy)
|
149
156
|
if use_http
|
150
|
-
DatadogHTTPClient.new logger, use_ssl, no_ssl_validation, host, port, use_compression, api_key, force_v1_routes
|
157
|
+
DatadogHTTPClient.new logger, use_ssl, no_ssl_validation, host, port, use_compression, api_key, force_v1_routes, http_proxy, -> { defined?(pipeline_shutdown_requested?) ? pipeline_shutdown_requested? : false }
|
151
158
|
else
|
152
159
|
DatadogTCPClient.new logger, use_ssl, no_ssl_validation, host, port
|
153
160
|
end
|
@@ -156,6 +163,9 @@ class LogStash::Outputs::DatadogLogs < LogStash::Outputs::Base
|
|
156
163
|
class RetryableError < StandardError;
|
157
164
|
end
|
158
165
|
|
166
|
+
class InterruptedError < StandardError;
|
167
|
+
end
|
168
|
+
|
159
169
|
class DatadogClient
|
160
170
|
def send_retries(payload, max_retries, max_backoff)
|
161
171
|
backoff = 1
|
@@ -165,16 +175,36 @@ class LogStash::Outputs::DatadogLogs < LogStash::Outputs::Base
|
|
165
175
|
rescue RetryableError => e
|
166
176
|
if retries < max_retries || max_retries < 0
|
167
177
|
@logger.warn("Retrying send due to: #{e.message}")
|
168
|
-
|
178
|
+
interruptableSleep(backoff)
|
169
179
|
backoff = 2 * backoff unless backoff > max_backoff
|
170
180
|
retries += 1
|
171
181
|
retry
|
172
182
|
end
|
183
|
+
@logger.error("Max number of retries reached, dropping message. Last exception: #{e.message}")
|
173
184
|
rescue => ex
|
174
|
-
|
185
|
+
if ex.is_a?(InterruptedError)
|
186
|
+
raise ex
|
187
|
+
else
|
188
|
+
@logger.error("Unmanaged exception while sending log to datadog #{ex.message}")
|
189
|
+
end
|
190
|
+
end
|
191
|
+
end
|
192
|
+
|
193
|
+
def interruptableSleep(duration)
|
194
|
+
amountSlept = 0
|
195
|
+
while amountSlept < duration
|
196
|
+
sleep 1
|
197
|
+
amountSlept += 1
|
198
|
+
if interrupted?
|
199
|
+
raise InterruptedError.new "Interrupted while backing off"
|
200
|
+
end
|
175
201
|
end
|
176
202
|
end
|
177
203
|
|
204
|
+
def interrupted?
|
205
|
+
false
|
206
|
+
end
|
207
|
+
|
178
208
|
def send(payload)
|
179
209
|
raise NotImplementedError, "Datadog transport client should implement the send method"
|
180
210
|
end
|
@@ -194,7 +224,8 @@ class LogStash::Outputs::DatadogLogs < LogStash::Outputs::Base
|
|
194
224
|
::Manticore::ResolutionFailure
|
195
225
|
]
|
196
226
|
|
197
|
-
def initialize(logger, use_ssl, no_ssl_validation, host, port, use_compression, api_key, force_v1_routes)
|
227
|
+
def initialize(logger, use_ssl, no_ssl_validation, host, port, use_compression, api_key, force_v1_routes, http_proxy, interruptedLambda = nil)
|
228
|
+
@interruptedLambda = interruptedLambda
|
198
229
|
@logger = logger
|
199
230
|
protocol = use_ssl ? "https" : "http"
|
200
231
|
|
@@ -216,9 +247,20 @@ class LogStash::Outputs::DatadogLogs < LogStash::Outputs::Base
|
|
216
247
|
|
217
248
|
config = {}
|
218
249
|
config[:ssl][:verify] = :disable if no_ssl_validation
|
250
|
+
if http_proxy != ""
|
251
|
+
config[:proxy] = http_proxy
|
252
|
+
end
|
219
253
|
@client = Manticore::Client.new(config)
|
220
254
|
end
|
221
255
|
|
256
|
+
def interrupted?
|
257
|
+
if @interruptedLambda
|
258
|
+
return @interruptedLambda.call
|
259
|
+
end
|
260
|
+
|
261
|
+
false
|
262
|
+
end
|
263
|
+
|
222
264
|
def send(payload)
|
223
265
|
begin
|
224
266
|
response = @client.post(@url, :body => payload, :headers => @headers).call
|
@@ -258,6 +300,7 @@ class LogStash::Outputs::DatadogLogs < LogStash::Outputs::Base
|
|
258
300
|
@no_ssl_validation = no_ssl_validation
|
259
301
|
@host = host
|
260
302
|
@port = port
|
303
|
+
@send_mutex = Mutex.new
|
261
304
|
end
|
262
305
|
|
263
306
|
def connect
|
@@ -278,13 +321,15 @@ class LogStash::Outputs::DatadogLogs < LogStash::Outputs::Base
|
|
278
321
|
end
|
279
322
|
|
280
323
|
def send(payload)
|
281
|
-
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
324
|
+
@send_mutex.synchronize do
|
325
|
+
begin
|
326
|
+
@socket ||= connect
|
327
|
+
@socket.puts(payload)
|
328
|
+
rescue => e
|
329
|
+
@socket.close rescue nil
|
330
|
+
@socket = nil
|
331
|
+
raise RetryableError.new "Unable to send payload: #{e.message}."
|
332
|
+
end
|
288
333
|
end
|
289
334
|
end
|
290
335
|
|
@@ -15,18 +15,27 @@ Gem::Specification.new do |s|
|
|
15
15
|
s.require_paths = ['lib']
|
16
16
|
|
17
17
|
# Files
|
18
|
-
s.files = Dir['lib/**/*', 'spec/**/*', 'vendor/**/*', '*.gemspec', '*.md', 'CONTRIBUTORS', 'Gemfile', 'LICENSE', 'NOTICE.TXT']
|
18
|
+
s.files = Dir['lib/**/*', 'spec/**/*', 'vendor/**/*', "vendor/jar-dependencies/**/*.jar", "vendor/jar-dependencies/**/*.rb", '*.gemspec', '*.md', 'CONTRIBUTORS', 'Gemfile', 'LICENSE', 'NOTICE.TXT']
|
19
19
|
# Tests
|
20
20
|
s.test_files = s.files.grep(%r{^(test|spec|features)/})
|
21
21
|
|
22
|
-
|
23
|
-
|
22
|
+
s.metadata = {
|
23
|
+
'bug_tracker_uri' => 'https://github.com/DataDog/logstash-output-datadog_logs/issues',
|
24
|
+
'changelog_uri' => 'https://github.com/DataDog/logstash-output-datadog_logs/blob/master/CHANGELOG.md',
|
25
|
+
'documentation_uri' => 'https://github.com/DataDog/logstash-output-datadog_logs/blob/master/README.md',
|
26
|
+
'source_code_uri' => 'https://github.com/DataDog/logstash-output-datadog_logs',
|
27
|
+
|
28
|
+
# Special flag to let us know this is actually a logstash plugin
|
29
|
+
"logstash_plugin" => "true",
|
30
|
+
"logstash_group" => "output",
|
31
|
+
}
|
24
32
|
|
25
33
|
# Gem dependencies
|
26
|
-
s.add_runtime_dependency "logstash-core-plugin-api", "
|
34
|
+
s.add_runtime_dependency "logstash-core-plugin-api", ">= 1.60", "<= 2.99"
|
27
35
|
s.add_runtime_dependency 'manticore', '>= 0.5.2', '< 1.0.0'
|
28
36
|
s.add_runtime_dependency 'logstash-codec-json'
|
37
|
+
s.add_runtime_dependency 'jar-dependencies', '>= 0.3.12', '< 0.5.0'
|
29
38
|
|
30
|
-
s.add_development_dependency 'logstash-devutils'
|
39
|
+
s.add_development_dependency 'logstash-devutils'
|
31
40
|
s.add_development_dependency 'webmock'
|
32
41
|
end
|
@@ -2,7 +2,7 @@
|
|
2
2
|
# under the Apache License Version 2.0.
|
3
3
|
# This product includes software developed at Datadog (https://www.datadoghq.com/).
|
4
4
|
# Copyright 2017 Datadog, Inc.
|
5
|
-
|
5
|
+
# encoding: utf-8
|
6
6
|
require "logstash/devutils/rspec/spec_helper"
|
7
7
|
require "logstash/outputs/datadog_logs"
|
8
8
|
require 'webmock/rspec'
|
@@ -90,12 +90,13 @@ describe LogStash::Outputs::DatadogLogs do
|
|
90
90
|
end
|
91
91
|
|
92
92
|
context "when facing HTTP connection issues" do
|
93
|
+
http_proxy = ""
|
93
94
|
[true, false].each do |force_v1_routes|
|
94
95
|
it "should retry when server is returning 5XX " + (force_v1_routes ? "using v1 routes" : "using v2 routes") do
|
95
96
|
api_key = 'XXX'
|
96
97
|
stub_dd_request_with_return_code(api_key, 500, force_v1_routes)
|
97
98
|
payload = '{}'
|
98
|
-
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes
|
99
|
+
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes, http_proxy
|
99
100
|
expect { client.send(payload) }.to raise_error(LogStash::Outputs::DatadogLogs::RetryableError)
|
100
101
|
end
|
101
102
|
|
@@ -103,7 +104,7 @@ describe LogStash::Outputs::DatadogLogs do
|
|
103
104
|
api_key = 'XXX'
|
104
105
|
stub_dd_request_with_return_code(api_key, 400, force_v1_routes)
|
105
106
|
payload = '{}'
|
106
|
-
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes
|
107
|
+
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes, http_proxy
|
107
108
|
expect { client.send(payload) }.to_not raise_error
|
108
109
|
end
|
109
110
|
|
@@ -111,7 +112,7 @@ describe LogStash::Outputs::DatadogLogs do
|
|
111
112
|
api_key = 'XXX'
|
112
113
|
stub_dd_request_with_return_code(api_key, 429, force_v1_routes)
|
113
114
|
payload = '{}'
|
114
|
-
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes
|
115
|
+
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes, http_proxy
|
115
116
|
expect { client.send(payload) }.to raise_error(LogStash::Outputs::DatadogLogs::RetryableError)
|
116
117
|
end
|
117
118
|
|
@@ -119,7 +120,7 @@ describe LogStash::Outputs::DatadogLogs do
|
|
119
120
|
api_key = 'XXX'
|
120
121
|
stub_dd_request_with_error(api_key, Manticore::Timeout, force_v1_routes)
|
121
122
|
payload = '{}'
|
122
|
-
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes
|
123
|
+
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes, http_proxy
|
123
124
|
expect { client.send(payload) }.to raise_error(LogStash::Outputs::DatadogLogs::RetryableError)
|
124
125
|
end
|
125
126
|
|
@@ -127,7 +128,7 @@ describe LogStash::Outputs::DatadogLogs do
|
|
127
128
|
api_key = 'XXX'
|
128
129
|
stub_dd_request_with_error(api_key, Manticore::SocketException, force_v1_routes)
|
129
130
|
payload = '{}'
|
130
|
-
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes
|
131
|
+
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes, http_proxy
|
131
132
|
expect { client.send(payload) }.to raise_error(LogStash::Outputs::DatadogLogs::RetryableError)
|
132
133
|
end
|
133
134
|
|
@@ -135,7 +136,7 @@ describe LogStash::Outputs::DatadogLogs do
|
|
135
136
|
api_key = 'XXX'
|
136
137
|
stub_dd_request_with_error(api_key, Manticore::ClientProtocolException, force_v1_routes)
|
137
138
|
payload = '{}'
|
138
|
-
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes
|
139
|
+
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes, http_proxy
|
139
140
|
expect { client.send(payload) }.to raise_error(LogStash::Outputs::DatadogLogs::RetryableError)
|
140
141
|
end
|
141
142
|
|
@@ -143,7 +144,7 @@ describe LogStash::Outputs::DatadogLogs do
|
|
143
144
|
api_key = 'XXX'
|
144
145
|
stub_dd_request_with_error(api_key, Manticore::ResolutionFailure, force_v1_routes)
|
145
146
|
payload = '{}'
|
146
|
-
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes
|
147
|
+
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes, http_proxy
|
147
148
|
expect { client.send(payload) }.to raise_error(LogStash::Outputs::DatadogLogs::RetryableError)
|
148
149
|
end
|
149
150
|
|
@@ -151,7 +152,7 @@ describe LogStash::Outputs::DatadogLogs do
|
|
151
152
|
api_key = 'XXX'
|
152
153
|
stub_dd_request_with_error(api_key, Manticore::SocketTimeout, force_v1_routes)
|
153
154
|
payload = '{}'
|
154
|
-
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes
|
155
|
+
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes, http_proxy
|
155
156
|
expect { client.send(payload) }.to raise_error(LogStash::Outputs::DatadogLogs::RetryableError)
|
156
157
|
end
|
157
158
|
|
@@ -159,7 +160,7 @@ describe LogStash::Outputs::DatadogLogs do
|
|
159
160
|
api_key = 'XXX'
|
160
161
|
stub_dd_request_with_error(api_key, StandardError, force_v1_routes)
|
161
162
|
payload = '{}'
|
162
|
-
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes
|
163
|
+
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes, http_proxy
|
163
164
|
expect { client.send(payload) }.to raise_error(StandardError)
|
164
165
|
end
|
165
166
|
|
@@ -167,7 +168,7 @@ describe LogStash::Outputs::DatadogLogs do
|
|
167
168
|
api_key = 'XXX'
|
168
169
|
stub_dd_request_with_error(api_key, StandardError, force_v1_routes)
|
169
170
|
payload = '{}'
|
170
|
-
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes
|
171
|
+
client = LogStash::Outputs::DatadogLogs::DatadogHTTPClient.new Logger.new(STDOUT), false, false, "datadog.com", 80, false, api_key, force_v1_routes, http_proxy
|
171
172
|
expect { client.send_retries(payload, 2, 2) }.to_not raise_error
|
172
173
|
end
|
173
174
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: logstash-output-datadog_logs
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Datadog
|
@@ -9,22 +9,28 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2025-05-05 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.60'
|
20
|
+
- - "<="
|
18
21
|
- !ruby/object:Gem::Version
|
19
|
-
version: '2.
|
22
|
+
version: '2.99'
|
20
23
|
name: logstash-core-plugin-api
|
21
|
-
prerelease: false
|
22
24
|
type: :runtime
|
25
|
+
prerelease: false
|
23
26
|
version_requirements: !ruby/object:Gem::Requirement
|
24
27
|
requirements:
|
25
|
-
- - "
|
28
|
+
- - ">="
|
26
29
|
- !ruby/object:Gem::Version
|
27
|
-
version: '
|
30
|
+
version: '1.60'
|
31
|
+
- - "<="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '2.99'
|
28
34
|
- !ruby/object:Gem::Dependency
|
29
35
|
requirement: !ruby/object:Gem::Requirement
|
30
36
|
requirements:
|
@@ -35,8 +41,8 @@ dependencies:
|
|
35
41
|
- !ruby/object:Gem::Version
|
36
42
|
version: 1.0.0
|
37
43
|
name: manticore
|
38
|
-
prerelease: false
|
39
44
|
type: :runtime
|
45
|
+
prerelease: false
|
40
46
|
version_requirements: !ruby/object:Gem::Requirement
|
41
47
|
requirements:
|
42
48
|
- - ">="
|
@@ -52,8 +58,8 @@ dependencies:
|
|
52
58
|
- !ruby/object:Gem::Version
|
53
59
|
version: '0'
|
54
60
|
name: logstash-codec-json
|
55
|
-
prerelease: false
|
56
61
|
type: :runtime
|
62
|
+
prerelease: false
|
57
63
|
version_requirements: !ruby/object:Gem::Requirement
|
58
64
|
requirements:
|
59
65
|
- - ">="
|
@@ -62,17 +68,37 @@ dependencies:
|
|
62
68
|
- !ruby/object:Gem::Dependency
|
63
69
|
requirement: !ruby/object:Gem::Requirement
|
64
70
|
requirements:
|
65
|
-
- -
|
71
|
+
- - ">="
|
66
72
|
- !ruby/object:Gem::Version
|
67
|
-
version:
|
68
|
-
|
73
|
+
version: 0.3.12
|
74
|
+
- - "<"
|
75
|
+
- !ruby/object:Gem::Version
|
76
|
+
version: 0.5.0
|
77
|
+
name: jar-dependencies
|
78
|
+
type: :runtime
|
69
79
|
prerelease: false
|
80
|
+
version_requirements: !ruby/object:Gem::Requirement
|
81
|
+
requirements:
|
82
|
+
- - ">="
|
83
|
+
- !ruby/object:Gem::Version
|
84
|
+
version: 0.3.12
|
85
|
+
- - "<"
|
86
|
+
- !ruby/object:Gem::Version
|
87
|
+
version: 0.5.0
|
88
|
+
- !ruby/object:Gem::Dependency
|
89
|
+
requirement: !ruby/object:Gem::Requirement
|
90
|
+
requirements:
|
91
|
+
- - ">="
|
92
|
+
- !ruby/object:Gem::Version
|
93
|
+
version: '0'
|
94
|
+
name: logstash-devutils
|
70
95
|
type: :development
|
96
|
+
prerelease: false
|
71
97
|
version_requirements: !ruby/object:Gem::Requirement
|
72
98
|
requirements:
|
73
|
-
- -
|
99
|
+
- - ">="
|
74
100
|
- !ruby/object:Gem::Version
|
75
|
-
version:
|
101
|
+
version: '0'
|
76
102
|
- !ruby/object:Gem::Dependency
|
77
103
|
requirement: !ruby/object:Gem::Requirement
|
78
104
|
requirements:
|
@@ -80,8 +106,8 @@ dependencies:
|
|
80
106
|
- !ruby/object:Gem::Version
|
81
107
|
version: '0'
|
82
108
|
name: webmock
|
83
|
-
prerelease: false
|
84
109
|
type: :development
|
110
|
+
prerelease: false
|
85
111
|
version_requirements: !ruby/object:Gem::Requirement
|
86
112
|
requirements:
|
87
113
|
- - ">="
|
@@ -107,6 +133,10 @@ homepage: https://www.datadoghq.com/
|
|
107
133
|
licenses:
|
108
134
|
- Apache-2.0
|
109
135
|
metadata:
|
136
|
+
bug_tracker_uri: https://github.com/DataDog/logstash-output-datadog_logs/issues
|
137
|
+
changelog_uri: https://github.com/DataDog/logstash-output-datadog_logs/blob/master/CHANGELOG.md
|
138
|
+
documentation_uri: https://github.com/DataDog/logstash-output-datadog_logs/blob/master/README.md
|
139
|
+
source_code_uri: https://github.com/DataDog/logstash-output-datadog_logs
|
110
140
|
logstash_plugin: 'true'
|
111
141
|
logstash_group: output
|
112
142
|
post_install_message:
|
@@ -124,8 +154,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
124
154
|
- !ruby/object:Gem::Version
|
125
155
|
version: '0'
|
126
156
|
requirements: []
|
127
|
-
|
128
|
-
rubygems_version: 2.7.6
|
157
|
+
rubygems_version: 3.3.26
|
129
158
|
signing_key:
|
130
159
|
specification_version: 4
|
131
160
|
summary: DatadogLogs lets you send logs to Datadog based on LogStash events.
|