Skip to content

Commit f4e4e00

Browse files
authored
Update strategy to understand if user customised decode_size_limit_bytes (#47)
Use `original_params` to understand if user has customised the setting and not just on the value.
1 parent d907249 commit f4e4e00

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

Diff for: CHANGELOG.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
## 3.2.2
2+
- Fix: updated the way to check if the `decode_size_limit_bytes` has been explicitly customised. [#47](https://github.com/logstash-plugins/logstash-codec-json_lines/pull/47)
3+
14
## 3.2.1
25
- Raise the default value of `decode_size_limit_bytes` up to 512 MB. [#46](https://github.com/logstash-plugins/logstash-codec-json_lines/pull/46)
36

Diff for: lib/logstash/codecs/json_lines.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ class LogStash::Codecs::JSONLines < LogStash::Codecs::Base
5757
public
5858

5959
def register
60-
if decode_size_limit_bytes == DEFAULT_DECODE_SIZE_LIMIT_BYTES
60+
if original_params['decode_size_limit_bytes'].nil?
6161
deprecation_logger.deprecated "The default value for `decode_size_limit_bytes`, currently at 512Mb, will be lowered in a future version to prevent Out of Memory errors from abnormally large messages or missing delimiters. Please set a value that reflects the largest expected message size (e.g. 20971520 for 20Mb)"
6262
end
6363
@buffer = FileWatch::BufferedTokenizer.new(@delimiter, @decode_size_limit_bytes)

Diff for: logstash-codec-json_lines.gemspec

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Gem::Specification.new do |s|
22

33
s.name = 'logstash-codec-json_lines'
4-
s.version = '3.2.1'
4+
s.version = '3.2.2'
55
s.licenses = ['Apache License (2.0)']
66
s.summary = "Reads and writes newline-delimited JSON"
77
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 gemname. This gem is not a stand-alone program"

0 commit comments

Comments
 (0)