Skip to content

feat: handle auto pagination for BigQuery v2 #3829

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

PhongChuong
Copy link
Contributor

Thank you for opening a Pull Request! Before submitting your PR, please read our contributing guidelines.

There are a few things you can do to make sure it goes smoothly:

  • Make sure to open an issue as a bug/issue before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea
  • Ensure the tests and linter pass
  • Code coverage does not decrease (if any source code was changed)
  • Appropriate docs were updated (if necessary)

Fixes # b/360114900 & b/352331075

@product-auto-label product-auto-label bot added the size: l Pull request size is large. label Jun 6, 2025
@PhongChuong PhongChuong marked this pull request as draft June 6, 2025 14:54
@PhongChuong PhongChuong marked this pull request as ready for review June 6, 2025 15:56
@PhongChuong
Copy link
Contributor Author

I'm unsure which checks are relevant/needed. Please let me know,
Thank you,

@blakeli0
Copy link
Collaborator

blakeli0 commented Jun 9, 2025

/gcbrun

PAGINATE_MAX_RESULT_TYPES =
ImmutableMap.of(
"com.google.cloud.bigquery.v2",
ImmutableMap.of(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess there are some legacy RPCs use max_results field and are not of wrapper types?

// This is similar to the PagedExpand except that it uses
// max_results instead of page_size, as some legacy APIs still
// do. New APIs should NOT use this pattern.
rpc PagedExpandLegacy(PagedExpandLegacyRequest) returns (PagedExpandResponse) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this test can prove much because the package is not bigquery, this is more like a negative test case which is already covered by other test cases. We need a positive golden test file that can demonstrate the changes.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are golden tests for this file missing?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size: l Pull request size is large.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants