logstash-filter-http 1.6.0 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8a4938972c776b2007e275e78c0dae1494ce21bc60ca4106972a7dc8501aa813
4
- data.tar.gz: c491efcaad17a7a926e1befd2bbc0ea01951a9d8fea989580a3ae0f1ab68a517
3
+ metadata.gz: 67615a61b9a26c149b07069dd2ebad2a1961ee8af6827e7dcbc0edf4e3b46341
4
+ data.tar.gz: ee9cff1c3372f69d8e3f41491f4e2d9f5a5ad41bf23c8976d143daf47307ba00
5
5
  SHA512:
6
- metadata.gz: cef735dd36b419dbbaa8aba20f0843db1c0bc97e4ca9c226410fd75e5bb033a4e100e3ab8bdff499c63832aedba959a0117d05db938f1c7935abb38d20f08fb3
7
- data.tar.gz: 0a376d1ce19dc7107abf07a89531dd2614b3ff25f4a573f20c5e01bdde95f926933e844c0190effa61c47f933b3ad086a6035f471efd82dffbc6c9359f8a46fe
6
+ metadata.gz: 7498c0f10356e10d499d175d7ace1ec18784db3eef2474a78c348caf89da56e0339708c76b9d1eb5e9a90dcf4a97561a1960f4ddba8a37f799ae1400ae417a1c
7
+ data.tar.gz: 964a464363ce043060639cef7cba71bf1c4400289cffd8c58cbea7fc2085c745d638efc76359449835c2bebfb2b5b4f44edd468435552198cf76e30be03246e4
data/CHANGELOG.md CHANGED
@@ -1,3 +1,18 @@
1
+ ## 2.0.0
2
+ - SSL settings that were marked deprecated in version `1.6.0` are now marked obsolete, and will prevent the plugin from starting.
3
+ - These settings are:
4
+ - `cacert`, which should be replaced by `ssl_certificate_authorities`
5
+ - `client_cert`, which should be replaced by `ssl_certificate`
6
+ - `client_key`, which should be replaced by `ssl_key`
7
+ - `keystore`, which should be replaced by `ssl_keystore_path`
8
+ - `keystore_password`, which should be replaced by `ssl_keystore_password`
9
+ - `keystore_type`, which should be replaced by `ssl_keystore_type`
10
+ - `truststore`, which should be replaced by `ssl_truststore_path>`
11
+ - `truststore_password`, which should be replaced by `ssl_truststore_password`
12
+ - `truststore_type`, which should be replaced by `ssl_truststore_type`
13
+ - [#54](https://github.com/logstash-plugins/logstash-filter-http/pull/54)
14
+
15
+
1
16
  ## 1.6.0
2
17
  - Added new `ssl_enabled` setting for enabling/disabling the SSL configurations [#52](https://github.com/logstash-plugins/logstash-filter-http/pull/52)
3
18
 
@@ -16,7 +16,7 @@ class LogStash::Filters::Http < LogStash::Filters::Base
16
16
 
17
17
  extend LogStash::PluginMixins::ValidatorSupport::FieldReferenceValidationAdapter
18
18
 
19
- include LogStash::PluginMixins::HttpClient[:with_deprecated => true]
19
+ include LogStash::PluginMixins::HttpClient[:with_obsolete => true]
20
20
 
21
21
  config_name 'http'
22
22
 
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'logstash-filter-http'
3
- s.version = '1.6.0'
3
+ s.version = '2.0.0'
4
4
  s.licenses = ['Apache License (2.0)']
5
5
  s.summary = 'This filter requests data from a RESTful Web Service.'
6
6
  s.description = 'This gem is a logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/logstash-plugin install logstash-filter-http. This gem is not a stand-alone program'
@@ -28,7 +28,7 @@ Gem::Specification.new do |s|
28
28
  # Gem dependencies
29
29
  s.add_runtime_dependency 'logstash-core-plugin-api', '>= 1.60', '<= 2.99'
30
30
  s.add_runtime_dependency 'logstash-mixin-ecs_compatibility_support', '~>1.2'
31
- s.add_runtime_dependency "logstash-mixin-http_client", ">= 7.4.0", "< 8.0.0"
31
+ s.add_runtime_dependency "logstash-mixin-http_client", ">= 7.5.0", "< 8.0.0"
32
32
  s.add_runtime_dependency 'logstash-mixin-validator_support', '~> 1.0'
33
33
 
34
34
  s.add_development_dependency 'logstash-devutils'
@@ -361,6 +361,31 @@ describe LogStash::Filters::Http do
361
361
  end
362
362
  end
363
363
 
364
+ describe "obsolete settings" do
365
+ let(:url) { 'https://a-non-existent.url1' }
366
+ let(:config) { { "url" => url, 'target_body' => '[the][body]' } }
367
+
368
+ [{:name => 'cacert', :canonical_name => 'ssl_certificate_authorities'},
369
+ {:name => 'client_cert', :canonical_name => 'ssl_certificate'},
370
+ {:name => 'client_key', :canonical_name => 'ssl_key'},
371
+ {:name => "keystore", :canonical_name => 'ssl_keystore_path'},
372
+ {:name => 'truststore', :canonical_name => 'ssl_truststore_path'},
373
+ {:name => "keystore_password", :canonical_name => "ssl_keystore_password"},
374
+ {:name => 'truststore_password', :canonical_name => "ssl_truststore_password"},
375
+ {:name => "keystore_type", :canonical_name => "ssl_keystore_type"},
376
+ {:name => 'truststore_type', :canonical_name => 'ssl_truststore_type'}
377
+ ].each do |settings|
378
+ context "with option #{settings[:name]}" do
379
+ let(:obsolete_config) { config.merge(settings[:name] => 'test_value') }
380
+
381
+ it "emits an error about the setting `#{settings[:name]}` now being obsolete and provides guidance to use `#{settings[:canonical_name]}`" do
382
+ error_text = /The setting `#{settings[:name]}` in plugin `http` is obsolete and is no longer available. Use `#{settings[:canonical_name]}` instead/i
383
+ expect { LogStash::Filters::Http.new(obsolete_config) }.to raise_error LogStash::ConfigurationError, error_text
384
+ end
385
+
386
+ end
387
+ end
388
+ end
364
389
  =begin
365
390
  # TODO refactor remaning tests to avoid whole pipeline instantiation
366
391
  describe 'empty response' do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logstash-filter-http
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.0
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Elastic
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-06-19 00:00:00.000000000 Z
11
+ date: 2024-12-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  requirement: !ruby/object:Gem::Requirement
@@ -20,8 +20,8 @@ dependencies:
20
20
  - !ruby/object:Gem::Version
21
21
  version: '2.99'
22
22
  name: logstash-core-plugin-api
23
- prerelease: false
24
23
  type: :runtime
24
+ prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  requirements:
27
27
  - - ">="
@@ -37,8 +37,8 @@ dependencies:
37
37
  - !ruby/object:Gem::Version
38
38
  version: '1.2'
39
39
  name: logstash-mixin-ecs_compatibility_support
40
- prerelease: false
41
40
  type: :runtime
41
+ prerelease: false
42
42
  version_requirements: !ruby/object:Gem::Requirement
43
43
  requirements:
44
44
  - - "~>"
@@ -49,18 +49,18 @@ dependencies:
49
49
  requirements:
50
50
  - - ">="
51
51
  - !ruby/object:Gem::Version
52
- version: 7.4.0
52
+ version: 7.5.0
53
53
  - - "<"
54
54
  - !ruby/object:Gem::Version
55
55
  version: 8.0.0
56
56
  name: logstash-mixin-http_client
57
- prerelease: false
58
57
  type: :runtime
58
+ prerelease: false
59
59
  version_requirements: !ruby/object:Gem::Requirement
60
60
  requirements:
61
61
  - - ">="
62
62
  - !ruby/object:Gem::Version
63
- version: 7.4.0
63
+ version: 7.5.0
64
64
  - - "<"
65
65
  - !ruby/object:Gem::Version
66
66
  version: 8.0.0
@@ -71,8 +71,8 @@ dependencies:
71
71
  - !ruby/object:Gem::Version
72
72
  version: '1.0'
73
73
  name: logstash-mixin-validator_support
74
- prerelease: false
75
74
  type: :runtime
75
+ prerelease: false
76
76
  version_requirements: !ruby/object:Gem::Requirement
77
77
  requirements:
78
78
  - - "~>"
@@ -85,8 +85,8 @@ dependencies:
85
85
  - !ruby/object:Gem::Version
86
86
  version: '0'
87
87
  name: logstash-devutils
88
- prerelease: false
89
88
  type: :development
89
+ prerelease: false
90
90
  version_requirements: !ruby/object:Gem::Requirement
91
91
  requirements:
92
92
  - - ">="
@@ -129,7 +129,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
129
129
  - !ruby/object:Gem::Version
130
130
  version: '0'
131
131
  requirements: []
132
- rubygems_version: 3.2.33
132
+ rubygems_version: 3.3.26
133
133
  signing_key:
134
134
  specification_version: 4
135
135
  summary: This filter requests data from a RESTful Web Service.