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

feat(bigquery): Add session mode support for queries #15553

Closed
quartzmo opened this issue Nov 2, 2021 · 0 comments · Fixed by #15699
Closed

feat(bigquery): Add session mode support for queries #15553

quartzmo opened this issue Nov 2, 2021 · 0 comments · Fixed by #15699
Assignees
Labels
api: bigquery Issues related to the BigQuery API. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.

Comments

@quartzmo
Copy link
Member

quartzmo commented Nov 2, 2021

There are several components to supporting sessions. Session support should expose these components, allowing users to manually associate queries with a session. It should not present a Session decorator or other high-level abstraction.

  • The CreateSession configuration property, which can be set as part of jobs.insert or jobs.query to create a session while executing the query.
  • The session_id for a query is returned back in the SessionInfo message in job statistics.
  • The ConnectionProperties field in query configuration allows users to set key-value pairs associated with queries. Users can populate the session_id key of the property list to associate subsequent queries with a previously created session.

Reference implementations:

@product-auto-label product-auto-label bot added the api: bigquery Issues related to the BigQuery API. label Nov 2, 2021
@quartzmo quartzmo self-assigned this Nov 2, 2021
@quartzmo quartzmo added the type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design. label Nov 2, 2021
quartzmo added a commit to quartzmo/google-cloud-ruby that referenced this issue Nov 4, 2021
* Add create_session and session_id params to Project#query_job
* Add session_id param to Project#query
* Add create_session and session_id params to Dataset#query_job
* Add session_id param to Dataset#query
* Add Job#session_id
* Add QueryJob::Updater#create_session=
* Add QueryJob::Updater#session_id=

closes: googleapis#15553
quartzmo added a commit that referenced this issue Nov 16, 2021
* Add create_session and session_id params to Project#query_job
* Add create_session and session_id params to Dataset#query_job
* Add session_id param to Project#query
* Add session_id param to Dataset#query
* Add Job#session_id
* Add QueryJob::Updater#create_session=
* Add QueryJob::Updater#session_id=

closes: #15553
pr: #15699
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 BigQuery API. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant