Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Option to use Streaming API #300

Open
harir91 opened this issue Dec 5, 2019 · 3 comments
Open

Option to use Streaming API #300

harir91 opened this issue Dec 5, 2019 · 3 comments
Labels
api: bigquery Issues related to the googleapis/python-bigquery-pandas API. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.

Comments

@harir91
Copy link

harir91 commented Dec 5, 2019

I believe that the core BQ Client now allows Streaming from a DataFrame.

I was wondering if we could make that an option in pandas-gbq to allow circumventing some of the limitations of the 1000 loads etc.

@tswast tswast added the type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design. label Dec 6, 2019
@tswast
Copy link
Collaborator

tswast commented Dec 6, 2019

Yes, this is much easier to implement now that the BigQuery client has an insert_rows_from_dataframe method.

Perhaps, a use_streaming_api parameter that defaults to False? Or if we want to support other upload mechanisms in the future (I anticipate the BQ Storage API adding a mechanism at some point), maybe upload_type='load' or upload_type='streaming' option.

@harir91
Copy link
Author

harir91 commented Dec 6, 2019

Correct, I think an upload_type or upload_mechanism is a more scaleable long-term approach to this.

@harir91
Copy link
Author

harir91 commented Dec 6, 2019

One thing to note is that there is a distinction in the way pandas-gbq handles Records/various structures and the way the Python BQ client does (insert_rows_from_dataframe) vs (to_gbq) in terms of what data structures are supported so should ensure that the two df's using to_gbq yield the same outcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: bigquery Issues related to the googleapis/python-bigquery-pandas API. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.
Projects
None yet
Development

No branches or pull requests

2 participants