-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for compression (gzip and deflate) #58
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, just left one question for my curiosity
lib/fluent/plugin/out_sumologic.rb
Outdated
desc 'Compress payload' | ||
config_param :compress, :bool, :default => false | ||
desc 'Encoding method of compresssion (either gzip or deflate)' | ||
config_param :compress_encoding, :string, :default => SumologicConnection::COMPRESS_DEFLATE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not too familiar with these, what was our reason for defaulting to deflate vs gzip?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would say consistency with logstash plugin:
Deflate seems to be more compact (shorter header) and faster.
Gzip includes additional headers and data validation, but uses deflate underneath
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also gzip looks to be preferred by HTTP society
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After some research I changed it to gzip. We can always change it back before release
1b7497d
to
9f37538
Compare
Add support for compression basing on logstash plugin
https://github.com/SumoLogic/logstash-output-sumologic/blob/master/lib/logstash/outputs/sumologic/compressor.rb