Repository navigation
Support lakehouse PCNT format in BigQueryIO storage read. - #39597
Conversation
|
Caution The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased. |
4810420 to
f6956de
Compare
|
Caution The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased. |
|
Reminder, please take a look at this pr: @ahmedabu98 |
|
Assigning new set of reviewers because Pr has gone too long without review. If you would like to opt out of this review, comment R: @chamikaramj for label java. Available commands:
|
| } else { | ||
| // Two colons - the last colon is an explicit project terminator. This is | ||
| // the canonical spelling for a domain-scoped project, whose id itself | ||
| // contains a colon ("example.com:proj:ds.t"), including with a composite | ||
| // Lakehouse catalog dataset ("example.com:proj:catalog.ns.t"). Both | ||
| // domain-scoped spellings keep toTableSpec/parseTableSpec a round trip | ||
| // for composite dataset ids. (More than two colons cannot form a valid | ||
| // reference - project ids contain at most one colon, but such specs pass | ||
| // the character-set gate, so they bind here too and the impossible | ||
| // project id is rejected by the service.) | ||
| int lastColon = prefix.lastIndexOf(':'); | ||
| project = prefix.substring(0, lastColon); | ||
| dataset = prefix.substring(lastColon + 1); | ||
| } |
There was a problem hiding this comment.
Should we make this else if (colonCount == 2) and throw an error on else? 3+ colons are not expected and should throw
ahmedabu98
left a comment
There was a problem hiding this comment.
Looks great. I reached out to some folks and will get back on the questions below
… DIRECT_READ Port of the Java change in apache#39597 to the Python SDK. - parse_table_reference now assigns segments by explicit splitting (mirroring BigQueryHelpers.parseTableSpec) so 4-part `project.catalog.namespace.table` and `project:catalog.namespace.table` specs map to a composite `catalog.namespace` dataset id. Previously the dotted form raised and the colon form silently bound the project to `project:catalog`. - Storage Read split tolerates tables that report no numBytes by requesting zero streams so the Read API picks the stream count; the export source's size estimate returns 0 instead of raising. - Unit tests for the new spec forms, domain-scoped projects, invalid specs, and the numBytes-missing paths.
#40225) * [Python] Support Lakehouse runtime catalog tables in ReadFromBigQuery DIRECT_READ Port of the Java change in #39597 to the Python SDK. - parse_table_reference now assigns segments by explicit splitting (mirroring BigQueryHelpers.parseTableSpec) so 4-part `project.catalog.namespace.table` and `project:catalog.namespace.table` specs map to a composite `catalog.namespace` dataset id. Previously the dotted form raised and the colon form silently bound the project to `project:catalog`. - Storage Read split tolerates tables that report no numBytes by requesting zero streams so the Read API picks the stream count; the export source's size estimate returns 0 instead of raising. - Unit tests for the new spec forms, domain-scoped projects, invalid specs, and the numBytes-missing paths. * comments * comments
Please add a meaningful description for your change here
Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:
addresses #123), if applicable. This will automatically add a link to the pull request in the issue. If you would like the issue to automatically close on merging the pull request, commentfixes #<ISSUE NUMBER>instead.CHANGES.mdwith noteworthy changes.See the Contributor Guide for more tips on how to make review process smoother.
To check the build health, please visit https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md
GitHub Actions Tests Status (on master branch)
See CI.md for more information about GitHub Actions CI or the workflows README to see a list of phrases to trigger workflows.