-
Notifications
You must be signed in to change notification settings - Fork 11
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
Adding ability to compress data when delivering to firehose #171
base: master
Are you sure you want to change the base?
Conversation
@@ -765,7 +765,7 @@ module.exports = function(configure) { | |||
logger.time("firehose request"); | |||
firehose.putRecordBatch({ | |||
Records: [{ | |||
Data: records.join('') | |||
Data: opts.gzipFirehose ? (records.map(r => r.toString("base64")).join('\n') + '\n') : records.join('') |
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.
@czirker Are we expecting the person using this to be gzipping the content themselves?
@@ -849,13 +849,13 @@ module.exports = function(configure) { | |||
enableLogging: true, | |||
snapshot: opts.snapshot | |||
}, opts.chunk || {}); | |||
chunkOpts.gzip = !opts.firehose; | |||
chunkOpts.gzip = opts.gzipFirehose || !opts.firehose; |
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.
@czirker Or is that what this does? The chunker does the gzipping?
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.
Correct. The chunker will do the zipping. The user just needs to specify that they want to enable the feature using gzipFirehose:true
Should not be merged until the bus portion has be released. Otherwise it will send events that can't be processed in firehose