googleapis / googleapis/google-cloud-python

read_gbq: add mechanism to ensure BQ storage API usage

未关闭
#14,472 2 条评论 1 个 reaction 已指派 1 人 已指派给 @TrevorBergeron 在 GitHub 查看
api: bigquery type: feature request
主要语言
Python
星标
5.4k
派生
1.8k
平均合并
3 天 4 小时
30 天内合并 PR
122

描述

**Assumption**: there is currently no supported way to force `read_gbq` to use the BQ storage API. I'd be happy to be corrected if I missed something!

**Is your feature request related to a problem? Please describe.**

I have cases where `read_gbq`'s heuristic chooses the JSON API, when I want the storage API. This is most noticeable for me on medium sized tables, which might take 5-20 seconds to load via the JSON API (comparatively these were much faster via the storage API). For many of my use cases: to make interactive use cases more bearable, I am very willing to pay the additional storage API cost.

**Describe the solution you'd like**

A parameter to read_gbq which forces the usage of the BQ storage API (including raising an error if the necessary deps are not available to do so). I won't try to be prescriptive about the details, though I'll note that the desired behavior I've described is what I expected from `use_bqstorage_api`, based on the name. From my understanding of the current behavior, `allow_bqstorage_api` is maybe more accurate.

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。