简体   繁体   English

无声地传送到 BigQuery,无法创建 BigQuery 表

[英]Beam to BigQuery silently failing to create BigQuery table

I am building a data pipeline from PubSub to Beam (Direct/Dataflow Runner) to Big Query.我正在构建从 PubSub 到 Beam(Direct/Dataflow Runner)再到 Big Query 的数据管道。 Today we started to run into issues where beam IO BigQuery connector stopped creating tables automatically and produced no error messages (Logging level set to DEBUG).今天我们开始遇到 beam IO BigQuery 连接器停止自动创建表并且没有生成错误消息(日志记录级别设置为 DEBUG)的问题。

Here is a snippet of what the BigQuery PTransform looks like:下面是 BigQuery PTransform 的一个片段:

beam.io.WriteToBigQuery(
                table=bq_table,
                schema=to_bq_schema(table),
                write_disposition=beam.io.BigQueryDisposition.WRITE_APPEND,
                create_disposition=beam.io.BigQueryDisposition.CREATE_IF_NEEDED)

Note that bq_table and schema should be correct.注意 bq_table 和 schema 应该是正确的。 We have tried even reducing the schema to single column.我们甚至尝试将架构减少到单列。

I was able to resolve the issue.我能够解决这个问题。 Turned out my timestamps had +00000 timezone awareness.原来我的时间戳具有 +00000 时区意识。 It was very difficult to debug this because it silently failed and is not trivial to attach a debugger on the runner.调试它非常困难,因为它悄无声息地失败了,而且在运行器上附加调试器也不是一件容易的事。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM