在管道模式下上传一堆数据

I need to upload result of DB-query to S3. The result is too big, so I don't want to store it locally. Also I want to compress the result before upload to S3.

Is it possible to do something like "pipe" in bash?

Thank you.

You can stream from your db reader through compression/gzip to a client writer with io.Pipe()