Pipub: Pipe data from the command line to Google Pubsub
Pipub is a command line tool that makes it easy to stream data to Google Cloud Pubsub.
Installation
To install pipub
, simply run:
$ pip install pipub
Quickstart
Before executing the command line tool you'll need a Google Cloud Project with a Pubsub topic.
Sending a local new line delimited JSON file to a Pubsub topic test
is as simple as running:
$ cat file.json | pipub test -p project-name
Peam will take care of sending each line as a new message to the test
topic.
This simplicity allows you to pipe the data to other programs before sending the data.