Skip to content

Commit

Permalink
fixing to work with cloudwatch logs kinesis subscriptions which gzip …
Browse files Browse the repository at this point in the history
…the records
  • Loading branch information
harold woo authored and harold woo committed May 11, 2016
1 parent d33a4fc commit 07eaaf0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/logstash/inputs/kinesis/worker.rb
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,10 @@ def checkpoint(checkpointer)
end

def process_record(record)
raw = @decoder.decode(record.getData).to_s
#raw = @decoder.decode(record.getData).to_s
is = com.fasterxml.jackson.databind.util::ByteBufferBackedInputStream.new(record.getData)
gzip = Java::java.util.zip::GZIPInputStream.new(is)
raw = gzip.to_io.read
@codec.decode(raw) do |event|
@decorator.call(event)
@output_queue << event
Expand Down

0 comments on commit 07eaaf0

Please sign in to comment.