【问题标题】:Dataflow needs bigquery.datasets.get permission for the underlying table in authorized view数据流需要 bigquery.datasets.get 授权视图中基础表的权限
【发布时间】:2018-11-06 07:24:39
【问题描述】:

在数据流管道中,我从 BigQuery 授权视图中读取数据:

beam.io.Read(beam.io.BigQuerySource(query = "SELECT col1 FROM proj2.dataset2.auth_view1", use_standard_sql=True))

这是我得到的错误:

错误: 消息:访问被拒绝:数据集 proj1:dataset1:用户 xxxxxx-compute@developer.gserviceaccount.com 没有数据集 proj1:dataset1 的 bigquery.datasets.get 权限。

proj1:dataset1 具有视图 auth_view1 的基表。

根据 DataflowJavaSDK 中的this 问题,dataflow 似乎正在直接对基础表执行一些元数据查询。

Apache Beam SDK 中是否有针对此问题的修复程序?

【问题讨论】:

  • 我使用 apache-beam 2.8.0

标签: google-cloud-platform google-bigquery google-cloud-dataflow apache-beam


【解决方案1】:

显式设置查询位置也是 Apache Beam Java SDK 中的一种解决方案,使用 BigQueryIO 的 withQueryLocation 选项。

在Python SDK 中似乎还不能设置查询位置。

【讨论】:

  • withQueryLocation 能解决这个问题吗?这是为什么呢?
  • 你好 Pablo,根据this withQueryLocation 选项将避免读取元数据。不幸的是,上次我检查时,此选项不适用于 Python SDK。
猜你喜欢
  • 2022-08-17
  • 2011-05-07
  • 1970-01-01
  • 2016-12-14
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2012-05-07
相关资源
最近更新 更多