Skip to content

Conversation

@blakeli0
Copy link
Contributor

@blakeli0 blakeli0 commented Feb 2, 2026

No description provided.

diegomarquezp and others added 30 commits December 4, 2025 16:46
* chore: add release-please config for protobuf-4.x

* Change release type from java-lts to java-yoshi
… data types (#4010)

* feat: Create DataFormatOptions in BigQuery

* feat: Add Builder class for DataFormatOptions

* fix: Update existing references of useInt64Timestamp to use DataFormatOption's variant

* chore: Fix lint issues

* chore: Address PR feedback

* chore: Add tests for useInt64Timestamp behavior

* chore: Address failing tests and GCA

* chore: Remove unused fromPb method
* feat: Add timestamp_precision to Field

* Apply suggestion from @gemini-code-assist[bot]

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>

* chore: Address GCA PR feedback

* chore: Fix typo

* chore: Remove default value

* chore: Address PR feedback

---------

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
…e than nanosecond precision (#4017)

* chore: Use custom timestamp validator for ISO8601 timestamps with more than nanosecond precision

* chore: Rename helper method to validateTimestamp

* chore: Address GCA comments

* chore: Address last GCA comment

* chore: Update to use assert helper method
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
* chore: Cleanup initialized resources

* chore: Delete created dataset

* chore: Use try-with to close stream
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
* chore: Cleanup initialized resources

* chore: Use try-with to close stream

* chore: Cleanup Intellij test warnings

* chore: Allow for floating point inaccuracies

* chore: Add otel delete operation
Co-authored-by: Blake Li <blakeli@google.com>
* chore: Cleanup initialized resources

* chore: Use try-with to close stream

* chore: Cleanup Intellij test warnings

* chore: Allow for floating point inaccuracies

* chore: Add otel delete operation

* chore: Clean up rest of the IT test file

* chore: Add GCA feedback
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
deps update from bigquerystorage was incorrectly marked as chore(deps). This would cause the upgrade not show up in the release notes and also not trigger release please.

This is because the pattern /^com.google.cloud:google-cloud-bigquery is configured in renovate.json, which matches both bigquery and bigquerystorage. However, I believe the original intention is only for bigquery update in samples, not for bigquerystorage update.

Fixing the pattern so that the String must ends with bigquery
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
* test: Add integration tests for picosecond support

* chore: Add a micro -> pico exact timestamp test case

* chore: Add additional test cases

* chore: Fix test cases with 'Z'

* chore: Test if first query has an impact

* chore: Remove flaky test for now

* chore: Remove testing comment
)

* fix: handled race condition in stateless query integration test

The testTableResultJobIdAndQueryId test was failing intermittently on slower networks. The test strictly asserted that Job ID must be null for stateless queries.

However, the library correctly falls back to creating a Job ID if the stateless query times out. This change updates the assertion logic to accept either a valid Query ID (stateless success) or a valid Job ID (fallback success).

Fixes #4008

* refactor: use XOR assertion for conciseness

 Applied feedback from code review to use exclusive OR operator for validating JobID/QueryID mutual exclusivity.

* fix: apply race condition logic to testStatelessQueries

Applied XOR assertion logic to testStatelessQueries. Test was failing on slow networks because they did not account for JOB_CREATION_OPTIONAL falling back to job creation.

Fixes #4002

* docs: add comment explaining stateless query fallback behavior

* docs: add comment explaining stateless query fallback behavior in testTableResultJobIdAndQueryId()
…ies check (#4048)

* chore: Ingore unused junit-jupiter-engine error in dependencies check

* chore: Update pom.xml

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>

* chore: Update comment format for junit-jupiter-engine

---------

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
#4047)

* fix: gracefully handle thread interruption in ConnectionImpl to prevent CI flakes

Fixes #3992

* fix: consolidate interrupt checks and handle raw InterruptedException as per review

* fix: remove CancelledException check per review feedback
* docs: Add specific samples for creating and query timestamps

* chore: Fix samples checkstyle issue

* chore: Address gemini suggestions

* chore: Update expiration time for test
* feat: Migrate to JUnit 5 and add parallel test execution

* feat: Migrate tests to JUnit5

* chore: Add surefire-junit-platform dep for ITs

* chore: Fix broken tests

* chore: Upgrade existing integration tests to JUnit 5 syntax and features

* chore: Upgrade ITNightlyBigQueryTest to JUnit 5 features and package-private

* chore: Make the tests package-private

* feat: migrate tests to JUnit 5 assertThrows and static imports

* chore: Remove wildcard imports

* chore: revert samples to use junit4

* chore: Address code comments

* chore: Close connection after test

---------

Co-authored-by: AbgarSim <abgar1223@gmail.com>
* feat: Migrate to JUnit 5 and add parallel test execution

* feat: Migrate tests to JUnit5

* chore: Add surefire-junit-platform dep for ITs

* test: Enable parallel tests for JUnit5

* chore: Fix broken tests

* chore: Upgrade existing integration tests to JUnit 5 syntax and features

* chore: Upgrade ITNightlyBigQueryTest to JUnit 5 features and package-private

* chore: Make the tests package-private

* feat: migrate tests to JUnit 5 assertThrows and static imports

* chore: Remove wildcard imports

* chore: revert samples to use junit4

* chore: Address code comments

* chore: Close connection after test

* chore: Fix flaky tests

* chore: Fix flaky tests

* chore: Fix tests

* chore: Disable cache for query stats

* chore: Add unique id to each table

* chore: Use unique test table names

* chore: Remove parallel test execution

* chore: Add comment for cache

* chore: Fix broken test

---------

Co-authored-by: AbgarSim <abgar1223@gmail.com>
* chore: cleanup release-please config

- Remove redundant options already declared at the top level.\n- Remove bumpMinorPreMajor for repositories after the first major release.

* chore: format release-please.yml
logachev and others added 6 commits January 15, 2026 12:23
…storage-bom to v3.19.1 (#4036)

* chore(deps): update dependency com.google.cloud:google-cloud-bigquerystorage-bom to v3.20.0-rc1

* Update google-cloud-bigquerystorage-bom version

---------

Co-authored-by: Diego Marquez <diegomarquezp@google.com>
* chore: Enable exponential backoff for retries in tests

* chore: Clone table for DML query tests

* chore: Use GCA retry settings code suggestion
* chore: Fix flaky testListTablesWithPartitioning test

* chore: Fix test comment

* chore: Fix typo to partitionType
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
@blakeli0 blakeli0 requested a review from a team as a code owner February 2, 2026 23:33
@blakeli0 blakeli0 requested review from keshavdandeva and removed request for a team February 2, 2026 23:33
@snippet-bot
Copy link

snippet-bot bot commented Feb 2, 2026

Here is the summary of changes.

You are about to add 1 region tag.

This comment is generated by snippet-bot.
If you find problems with this result, please file an issue at:
https://github.com/googleapis/repo-automation-bots/issues.
To update this comment, add snippet-bot:force-run label or use the checkbox below:

  • Refresh this comment

@product-auto-label product-auto-label bot added size: xl Pull request size is extra large. api: bigquery Issues related to the googleapis/java-bigquery API. labels Feb 2, 2026
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @blakeli0, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request primarily focuses on merging release v2.57.2 into the protobuf-3.x branch, which encompasses the significant introduction of a new BigQuery JDBC driver. This new driver provides standard Java Database Connectivity for BigQuery, enabling applications to interact with BigQuery using familiar SQL interfaces. Alongside this major feature, the PR also includes routine dependency updates and minor repository configuration adjustments to support the new driver and maintain release processes.

Highlights

  • BigQuery JDBC Driver Introduction: A new BigQuery JDBC driver has been introduced, including its core implementation, exception handling, and build configurations, enabling standard Java Database Connectivity for BigQuery.
  • Dependency Updates: Several dependencies have been updated, including GraalVM images (from 3.54.1 to 3.55.1) and the google-cloud-bigquery-bom (from 2.56.0 to 2.57.2), ensuring compatibility and leveraging the latest improvements.
  • Changelog Updates: The CHANGELOG.md has been updated to reflect recent releases (2.57.2, 2.57.1, 2.57.0), detailing bug fixes (thread interruption, Job.isDone()), new features (timestamp_precision, DataFormatOptions, relaxed entity ID validation), and dependency updates.
  • Repository Configuration: Updates to .github/CODEOWNERS assign ownership for the new JDBC driver, modifications to .gitignore include JDBC-specific files, and adjustments in .github/release-please.yml streamline release management processes.
Changelog
  • .github/CODEOWNERS
    • Added ownership rules for the new google-cloud-bigquery-jdbc directory.
  • .github/release-please.yml
    • Updated release configuration to include a protobuf-4.x-rc branch and streamlined bumpMinorPreMajor settings across various branches.
  • .gitignore
    • Added new ignore patterns for JDBC-specific build artifacts and directories (google-cloud-bigquery-jdbc/drivers/, google-cloud-bigquery-jdbc/jacoco*).
  • .kokoro/continuous/graalvm-native-a.cfg
    • Updated the TRAMPOLINE_IMAGE version from 3.54.1 to 3.55.1.
  • .kokoro/continuous/graalvm-native-b.cfg
    • Updated the TRAMPOLINE_IMAGE version from 3.54.1 to 3.55.1.
  • .kokoro/continuous/graalvm-native-c.cfg
    • Updated the TRAMPOLINE_IMAGE version from 3.54.1 to 3.55.1.
  • .kokoro/presubmit/graalvm-native-a.cfg
    • Updated the TRAMPOLINE_IMAGE version from 3.54.1 to 3.55.1.
  • .kokoro/presubmit/graalvm-native-b.cfg
    • Updated the TRAMPOLINE_IMAGE version from 3.54.1 to 3.55.1.
  • .kokoro/presubmit/graalvm-native-c.cfg
    • Updated the TRAMPOLINE_IMAGE version from 3.54.1 to 3.55.1.
  • CHANGELOG.md
    • Appended entries for versions 2.57.2, 2.57.1, and 2.57.0, detailing bug fixes, new features, and dependency updates.
  • README.md
    • Removed the "CI Status" section and associated badges.
  • benchmark/pom.xml
    • Updated the google-cloud-bigquery-parent version to 2.57.2.
  • google-cloud-bigquery-bom/pom.xml
    • Updated google-cloud-bigquery-bom to 2.57.2 and sdk-platform-java-config to 3.55.1.
  • google-cloud-bigquery-jdbc/Dockerfile
    • Added Dockerfile for building the JDBC driver.
  • google-cloud-bigquery-jdbc/Makefile
    • Added Makefile for JDBC driver build and test automation.
  • google-cloud-bigquery-jdbc/pom.xml
    • Added Maven Project Object Model for the new JDBC driver, defining its dependencies and build profiles.
  • google-cloud-bigquery-jdbc/src/main/java/com/google/cloud/bigquery/exception/*.java
    • Introduced new exception classes (BigQueryConversionException, BigQueryJdbcCoercionException, BigQueryJdbcCoercionNotFoundException, BigQueryJdbcException, BigQueryJdbcRuntimeException, BigQueryJdbcSqlFeatureNotSupportedException, BigQueryJdbcSqlSyntaxErrorException) for specific JDBC error handling.
  • google-cloud-bigquery-jdbc/src/main/java/com/google/cloud/bigquery/jdbc/*.java
    • Added numerous core Java classes implementing the BigQuery JDBC driver functionality, including BigQueryArrowArray, BigQueryArrowBatchWrapper, BigQueryArrowResultSet, BigQueryArrowStruct, BigQueryBaseArray, BigQueryBaseResultSet, BigQueryBaseStruct, BigQueryCallableStatement, BigQueryCoercion, BigQueryConnection, BigQueryConnectionProperty, BigQueryDaemonPollingTask, BigQueryDefaultCoercions, BigQueryDriver, BigQueryErrorMessage, BigQueryFieldValueListWrapper, BigQueryJdbcBulkInsertWriter, BigQueryJdbcCustomLogger, BigQueryJdbcOAuthUtility, BigQueryJdbcParameter, BigQueryJdbcProxyUtility, BigQueryJdbcRootLogger, BigQueryJdbcTypeMappings, BigQueryJdbcUrlUtility, BigQueryJsonArray, BigQueryJsonResultSet, BigQueryJsonStruct, BigQueryNoOpsConnection, BigQueryNoOpsResultSet, BigQueryNoOpsStatement, BigQueryParameterHandler, BigQueryPooledConnection, BigQueryPreparedStatement, BigQueryResultSet, BigQueryResultSetFinalizers, BigQueryResultSetMetadata, BigQuerySettings, BigQuerySqlTypeConverter, BigQueryStatement, BigQueryThreadFactory, BigQueryTypeCoercer, BigQueryTypeCoercerBuilder, BigQueryTypeCoercionUtility, DataSource, PooledConnectionDataSource, PooledConnectionListener.
  • google-cloud-bigquery-jdbc/src/main/resources/META-INF/services/java.sql.Driver
    • Registered com.google.cloud.bigquery.jdbc.BigQueryDriver as a JDBC driver.
  • google-cloud-bigquery-jdbc/src/main/resources/com/google/cloud/bigquery/jdbc/*.sql
    • Added SQL query templates for DatabaseMetaData methods (GetCrossReference.sql, GetExportedKeys.sql, GetImportedKeys.sql, GetPrimaryKeys.sql).
  • google-cloud-bigquery-jdbc/src/main/resources/com/google/cloud/bigquery/jdbc/dependencies.properties
    • Added version property for the JDBC driver.
  • google-cloud-bigquery-jdbc/src/test/java/com/google/cloud/bigquery/jdbc/*.java
    • Added comprehensive unit tests for the new JDBC driver components, including ArrowFormatTypeBigQueryCoercionUtilityTest, BigQueryArrowArrayOfPrimitivesTest, BigQueryArrowArrayOfStructTest, BigQueryArrowResultSetTest, BigQueryArrowStructTest, BigQueryBaseResultSetTest, BigQueryBigQueryTypeCoercerBuilderTest, BigQueryCallableStatementTest, BigQueryConnectionTest, BigQueryDaemonPollingTaskTest.
Ignored Files
  • Ignored by pattern: .github/workflows/** (2)
    • .github/workflows/scorecard.yml
    • .github/workflows/unmanaged_dependency_check.yaml
Activity
  • No human activity has been recorded for this pull request.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Contributor

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

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 introduces a significant amount of new code to add a BigQuery JDBC driver. The changes include the driver implementation, connection and statement classes, type mappings, exception handling, and build configurations. The overall structure is well-designed, with good separation of concerns and use of modern Java features.

I've found a couple of issues:

  • In the Makefile for the JDBC driver, there's a minor bug in the docker-package target where a rm command targets the wrong directory.
  • In BigQueryJdbcTypeMappings, there's a logic error in the classToType method that prevents correct mapping for some String and BigDecimal subtypes.

Apart from these points, the implementation looks solid. The addition of the JDBC driver is a great enhancement.

Comment on lines +103 to +118
} else if (String.class.isAssignableFrom(type)) {
return StandardSQLTypeName.GEOGRAPHY;
} else if (String.class.isAssignableFrom(type)) {
return StandardSQLTypeName.DATETIME;
} else if (Integer.class.isAssignableFrom(type)) {
return StandardSQLTypeName.INT64;
} else if (Long.class.isAssignableFrom(type)) {
return StandardSQLTypeName.INT64;
} else if (Double.class.isAssignableFrom(type)) {
return StandardSQLTypeName.FLOAT64;
} else if (Float.class.isAssignableFrom(type)) {
return StandardSQLTypeName.FLOAT64;
} else if (BigDecimal.class.isAssignableFrom(type)) {
return StandardSQLTypeName.NUMERIC;
} else if (BigDecimal.class.isAssignableFrom(type)) {
return StandardSQLTypeName.BIGNUMERIC;
Copy link
Contributor

Choose a reason for hiding this comment

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

high

The if-else if chain for String.class will always resolve to StandardSQLTypeName.STRING on line 102 and never reach the GEOGRAPHY or DATETIME cases on lines 104 and 106. This prevents setting parameters of these types from a Java String. A similar issue exists for BigDecimal on lines 115-118, which will always resolve to NUMERIC and never BIGNUMERIC.

This logic needs to be revisited to allow for correct type mapping.

sh -c "make package && \
mkdir -p /tmp/package && \
cp --no-preserve=ownership /mvn/test-target/google-cloud-bigquery-jdbc-*.jar /tmp/package && \
rm -f /pkg/*tests.jar && \
Copy link
Contributor

Choose a reason for hiding this comment

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

medium

The rm -f /pkg/*tests.jar command appears to target the wrong directory. In the preceding steps, files are copied to /tmp/package, but this command attempts to remove files from /pkg. As a result, test JARs might be unintentionally included in the final zip archive. The command should probably be rm -f /tmp/package/*tests.jar to correctly remove the test JARs before packaging.

			rm -f /tmp/package/*tests.jar && \

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 googleapis/java-bigquery API. size: xl Pull request size is extra large.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants