如何从Apache Beam Python读取S3文件?
我正在使用Apache Beam Python SDK读取S3文件数据。
我正在使用的代码
ip = (pipe
| beam.io.ReadFromText("s3://bucket_name/file_path")
| beam.Map(lambda x: x.split(","))
| beam.Map(print)
)
,但它给
S3ClientError('Unable to locate credentials', None)}")}
任何人都知道如何向S3客户端thorugh apache beam Python文件提供凭据
I am using Apache Beam python SDK to read s3 file data.
code I am using
ip = (pipe
| beam.io.ReadFromText("s3://bucket_name/file_path")
| beam.Map(lambda x: x.split(","))
| beam.Map(print)
)
but it gives a error
S3ClientError('Unable to locate credentials', None)}")}
Anybody have any idea how to give credentials to s3 client thorugh apache beam python file
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您需要确保工具机上的凭据可用。做到这一点的一种方法是将它们安装在a 自定义容器 。
You need to ensure the credentials are available on your worker machines. One way to do this is installing them in a custom container.