chovy-3012 commented on PR #13088:
URL: https://github.com/apache/seatunnel/pull/13088#issuecomment-6745306065
Thanks @DanielLeens for the re-review and approval!
Both items are fixed in 76fff675b (new commit on top of the reviewed head).
**Issue A — `maxResults=1` fallback restricted to the emulator**
`resolveFromQuery` now fails fast before the fallback whenever the dry-run
statistics come back without a schema and `emulator_host` is not configured:
```text
discoverSchemaViaDryRun (dryRun=true, free)
├─ schema present → use it (unchanged)
└─ schema missing
├─ emulator_host unset → fail fast: "Query schema could not be
determined by dry
│ run ... only supported with emulator_host"
└─ emulator_host set → WARN + maxResults=1 fallback (unchanged
emulator path)
```
`emulator_host` is the gate because `BigQueryClientFactory` builds the
emulator client from that same option, so the gate cannot disagree with the
client actually in use. Locked in by a new UT,
`testResolveFromQueryRejectsFallbackWithoutEmulatorHost`: no `emulator_host` +
missing dry-run schema → the fail-fast error (message includes the remediation
hint) and `verify(bigQuery, never()).query(...)`, while the dry-run
`create(...)` did happen. The two existing fallback tests now set
`emulator_host` explicitly so they still cover the fallback branch itself. Docs
(en/zh `BigQuery.md:68`) now state the fallback is emulator-only and that
without `emulator_host` planning fails fast instead of executing the query. The
IT and E2E configs already set `emulator_host`, so they are unaffected.
**Issue B:** Docs fixed in both languages: table mode reads metadata via the
SDK's `bigQuery.getTable()`, and the cap sentence now says the dry run only
logs a WARN when the estimate exceeds `maximum_bytes_billed` — BigQuery
enforces the cap on executed jobs only.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]