Skip to content

test(bigquery-jdbc): add Storage Write API all-types parity and SQL-fallback integration tests - #15109

Closed
Neenu1995 wants to merge 1 commit into
fix/swa-proto-4-direct-insert-gatingfrom
fix/swa-proto-5-integration-tests
Closed

Neenu1995 wants to merge 1 commit into
fix/swa-proto-4-direct-insert-gatingfrom
fix/swa-proto-5-integration-tests

Conversation

@Neenu1995

Copy link
Copy Markdown
Contributor

Stack: PR 5 of 5

Summary

  • Add end-to-end integration regression tests in ITNightlyBigQueryTest verifying cell-by-cell ResultSet parity (and asserting Storage Write API vs. standard SQL execution path via driver logs) between EnableWriteAPI=1 (ProtoSchema Storage Write API) and EnableWriteAPI=0 (standard SQL DML) across BigQuery data types (STRING including non-ASCII/hyphenated column `c-str-é`, BYTES, INT64, FLOAT64, NUMERIC, NUMERIC(10, 2), BIGNUMERIC, BOOL, DATE, TIME, DATETIME, TIMESTAMP, JSON, and NULL GEOGRAPHY/INTERVAL), NULL rows, and reordered column lists.
  • Add end-to-end integration tests verifying automatic SQL DML fallback when EnableWriteAPI=1 is used with SQL functions/expressions in VALUES (...) (UPPER(?), SHA256(?), and non-null ST_GEOGFROMTEXT(?), MAKE_INTERVAL(...), PARSE_JSON(?)) or complex ARRAY/STRUCT/RANGE target tables.

Testing

  • make lint, mvn -B -ntp verify -DskipTests -DskipITs, mvn -B -ntp dependency:analyze-only -DfailOnWarning=true, mvn -q -Denforcer.skip=true -Dclirr.skip=true test-compile, and full make unittest (credentialed live execution of ITNightlyBigQueryTest requires GOOGLE_APPLICATION_CREDENTIALS in CI).

…allback integration tests

Stack: PR 5 of 5 (base: `fix/swa-proto-4-direct-insert-gating`)

### Summary
- Add end-to-end integration regression tests in `ITNightlyBigQueryTest` verifying cell-by-cell ResultSet parity (and asserting Storage Write API vs. standard SQL execution path via driver logs) between `EnableWriteAPI=1` (`ProtoSchema` Storage Write API) and `EnableWriteAPI=0` (standard SQL DML) across BigQuery data types (`STRING` including non-ASCII/hyphenated column `` `c-str-é` ``, `BYTES`, `INT64`, `FLOAT64`, `NUMERIC`, `NUMERIC(10, 2)`, `BIGNUMERIC`, `BOOL`, `DATE`, `TIME`, `DATETIME`, `TIMESTAMP`, `JSON`, and `NULL` `GEOGRAPHY`/`INTERVAL`), `NULL` rows, and reordered column lists.
- Add end-to-end integration tests verifying automatic SQL DML fallback when `EnableWriteAPI=1` is used with SQL functions/expressions in `VALUES (...)` (`UPPER(?)`, `SHA256(?)`, and non-null `ST_GEOGFROMTEXT(?)`, `MAKE_INTERVAL(...)`, `PARSE_JSON(?)`) or complex `ARRAY`/`STRUCT`/`RANGE` target tables.

### Testing
- `make lint`, `mvn -B -ntp verify -DskipTests -DskipITs`, `mvn -B -ntp dependency:analyze-only -DfailOnWarning=true`, `mvn -q -Denforcer.skip=true -Dclirr.skip=true test-compile`, and full `make unittest` (credentialed live execution of `ITNightlyBigQueryTest` requires `GOOGLE_APPLICATION_CREDENTIALS` in CI).
@Neenu1995
Neenu1995 requested review from a team as code owners November 20, 2026 20:26

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request adds integration tests to ITNightlyBigQueryTest.java to verify the behavior of bulk inserts using the BigQuery Storage Write API. Specifically, it introduces testBulkInsertWriteApiAllTypesParityWithStandardSql to ensure data type parity between the Write API and standard SQL, and testBulkInsertWriteApiSqlExpressionAndComplexTypeFallback to validate fallback behavior to standard SQL when SQL expressions or complex types are present. Helper methods for populating test batches and asserting Write API usage via logs were also added. There are no review comments, and I have no additional feedback to provide.

@Neenu1995
Neenu1995 added this pull request to stack #15111 November 20, 2026 20:31
@Neenu1995
Neenu1995 deleted the branch fix/swa-proto-4-direct-insert-gating November 20, 2026 23:27
@Neenu1995 Neenu1995 closed this Nov 20, 2026
@Neenu1995
Neenu1995 deleted the fix/swa-proto-5-integration-tests branch November 20, 2026 23:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant