I was in need of a way to feed large amounts JSON of data into Kinesis Firehose, so I could work out a bunch of other downstream logic. While the AWS CLI does allow me to push data, I have to call out each line I want to write as arguments to the command, and it has issues with some characters, meaning the data in didn’t always match the data out.
Though this seems like a pretty generic need, I couldn’t find any portable tools out there to push data from a file or pipe from stdin/stdout to a Firehose, so I decided to write my own, called pipe2firehose.
To install, download from Github release page or run:
1 | go get github.com/Brayyy/pipe2firehose |
https://github.com/Brayyy/pipe2firehose
A simple tool to pipe data from stdin and push into AWS Kinesis Firehose or Kinesis Stream.
1 | Usage: |
This is far superior for my use case compared to the AWS CLI method, requiring a lot of string replacing to even get the records to be postable:
1 | # Not really sustainable when you need to push 500,000 lines |