从Dataflow中的压缩文件中读取 [英] Reading from compressed files in Dataflow

查看:62
本文介绍了从Dataflow中的压缩文件中读取的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法(或任何形式的破解)从压缩文件中读取输入数据? 我的输入包含数百个文件,这些文件是使用gzip压缩后生成的,解压缩有些乏味.

Is there a way (or any kind of hack) to read input data from compressed files? My input consists of a few hundreds of files, which are produced as compressed with gzip and uncompressing them is somewhat tedious.

谢谢, Genady

Thanks, Genady

推荐答案

我还发现,对于驻留在云存储中的文件,设置内容类型和内容编码似乎正常",而无需解决方法.

I also found that for files that reside in the cloud store, setting the content type and content encoding appears to "just work" without the need for a workaround.

特别是-我跑步

gsutil -m setmeta -h "Content-Encoding:gzip" -h "Content-Type:text/plain" <path>

这篇关于从Dataflow中的压缩文件中读取的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆