diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml
index f60d77493..a79f06271 100644
--- a/.github/.OwlBot.lock.yaml
+++ b/.github/.OwlBot.lock.yaml
@@ -13,5 +13,5 @@
# limitations under the License.
docker:
image: gcr.io/cloud-devrel-public-resources/owlbot-java:latest
- digest: sha256:fc52b202aa298a50a12c64efd04fea3884d867947effe2fa85382a246c09e813
-# created: 2022-04-06T16:30:03.627422514Z
+ digest: sha256:2567a120ce90fadb6201999b87d649d9f67459de28815ad239bce9ebfaa18a74
+# created: 2022-05-19T15:12:45.278246753Z
diff --git a/.kokoro/build.sh b/.kokoro/build.sh
index 3c45ad23a..089ca0e23 100755
--- a/.kokoro/build.sh
+++ b/.kokoro/build.sh
@@ -80,11 +80,16 @@ nightly-it)
verify
RETURN_CODE=$?
;;
-#graalvm)
-# # Run Unit and Integration Tests with Native Image
-# mvn -B ${INTEGRATION_TEST_ARGS} -ntp -Pnative -Penable-integration-tests test
-# RETURN_CODE=$?
-# ;;
+graalvm)
+ # Run Unit and Integration Tests with Native Image
+ mvn -B ${INTEGRATION_TEST_ARGS} -ntp -Pnative -Penable-integration-tests test
+ RETURN_CODE=$?
+ ;;
+graalvm17)
+ # Run Unit and Integration Tests with Native Image. Skip Arrow tests until https://github.com/googleapis/java-bigquery/issues/2060 is fixed.
+ mvn -B ${INTEGRATION_TEST_ARGS} -ntp -Pnative -Penable-integration-tests test "-Dtest=!com.google.cloud.bigquery.it.ITBigQueryTest#testBQResultSetPaginationSlowQuery+testReadAPIConnectionMultiClose+testReadAPIIterationAndOrder, !com.google.cloud.bigquery.it.ITNightlyBigQueryTest#testIterateAndOrder+testMultipleRuns+testIterateAndOrderDefaultConnSettings, IT*, *ClientTest"
+ RETURN_CODE=$?
+ ;;
samples)
SAMPLES_DIR=samples
# only run ITs in snapshot/ on presubmit PRs. run ITs in all 3 samples/ subdirectories otherwise.
diff --git a/.kokoro/presubmit/graalvm-native-17.cfg b/.kokoro/presubmit/graalvm-native-17.cfg
new file mode 100644
index 000000000..a3f7fb9d4
--- /dev/null
+++ b/.kokoro/presubmit/graalvm-native-17.cfg
@@ -0,0 +1,33 @@
+# Format: //devtools/kokoro/config/proto/build.proto
+
+# Configure the docker image for kokoro-trampoline.
+env_vars: {
+ key: "TRAMPOLINE_IMAGE"
+ value: "gcr.io/cloud-devrel-kokoro-resources/graalvm17"
+}
+
+env_vars: {
+ key: "JOB_TYPE"
+ value: "graalvm17"
+}
+
+# TODO: remove this after we've migrated all tests and scripts
+env_vars: {
+ key: "GCLOUD_PROJECT"
+ value: "gcloud-devel"
+}
+
+env_vars: {
+ key: "GOOGLE_CLOUD_PROJECT"
+ value: "gcloud-devel"
+}
+
+env_vars: {
+ key: "GOOGLE_APPLICATION_CREDENTIALS"
+ value: "secret_manager/java-it-service-account"
+}
+
+env_vars: {
+ key: "SECRET_MANAGER_KEYS"
+ value: "java-it-service-account"
+}
\ No newline at end of file
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 28a298be5..56c529d65 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,27 @@
# Changelog
+## [2.12.0](https://github.com/googleapis/java-bigquery/compare/v2.11.2...v2.12.0) (2022-05-25)
+
+
+### Features
+
+* add build scripts for native image testing in Java 17 ([#1440](https://github.com/googleapis/java-bigquery/issues/1440)) ([#2057](https://github.com/googleapis/java-bigquery/issues/2057)) ([065ae78](https://github.com/googleapis/java-bigquery/commit/065ae78ef20052032c245b3fe991808c24ec8077))
+
+
+### Bug Fixes
+
+* add more native image configurations for Arrow tests and enable native image tests ([#2053](https://github.com/googleapis/java-bigquery/issues/2053)) ([7f0bfd4](https://github.com/googleapis/java-bigquery/commit/7f0bfd4a42c28f3d2a748474e1ec40740311a734))
+* Flaky testPositionalQueryParameters ([#2059](https://github.com/googleapis/java-bigquery/issues/2059)) ([3764b59](https://github.com/googleapis/java-bigquery/commit/3764b5967c694fa34aef75804333e5a6101d912e))
+
+
+### Dependencies
+
+* update dependency com.google.cloud:google-cloud-bigtable to v2.7.0 ([#2061](https://github.com/googleapis/java-bigquery/issues/2061)) ([1c7a0ab](https://github.com/googleapis/java-bigquery/commit/1c7a0ab157f79772d8da58bfe15f54a7394124e8))
+* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.11.0 ([#2055](https://github.com/googleapis/java-bigquery/issues/2055)) ([9667663](https://github.com/googleapis/java-bigquery/commit/9667663fbec20f262c218f07cce1ada0c9a4bce0))
+* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.12.0 ([#2063](https://github.com/googleapis/java-bigquery/issues/2063)) ([6d3f4be](https://github.com/googleapis/java-bigquery/commit/6d3f4bead2315703015bd75711fcbf19428fad6e))
+* update dependency com.google.cloud:google-cloud-storage to v2.7.0 ([#2064](https://github.com/googleapis/java-bigquery/issues/2064)) ([fd47710](https://github.com/googleapis/java-bigquery/commit/fd47710afdf32fd535f8e2b430156eb4a659a64d))
+* update dependency com.google.cloud:google-cloud-storage to v2.7.1 ([#2066](https://github.com/googleapis/java-bigquery/issues/2066)) ([89962a5](https://github.com/googleapis/java-bigquery/commit/89962a5e3cec0e5a4334454b1bff83fba3d95d4d))
+
### [2.11.2](https://github.com/googleapis/java-bigquery/compare/v2.11.1...v2.11.2) (2022-05-18)
diff --git a/README.md b/README.md
index ef43a359a..0d2537d09 100644
--- a/README.md
+++ b/README.md
@@ -44,7 +44,7 @@ If you are using Maven without BOM, add this to your dependencies:
com.google.cloud
google-cloud-bigquery
- 2.11.1
+ 2.11.2
```
@@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-bigquery'
If you are using Gradle without BOM, add this to your dependencies
```Groovy
-implementation 'com.google.cloud:google-cloud-bigquery:2.11.1'
+implementation 'com.google.cloud:google-cloud-bigquery:2.11.2'
```
If you are using SBT, add this to your dependencies
```Scala
-libraryDependencies += "com.google.cloud" % "google-cloud-bigquery" % "2.11.1"
+libraryDependencies += "com.google.cloud" % "google-cloud-bigquery" % "2.11.2"
```
## Authentication
diff --git a/benchmark/pom.xml b/benchmark/pom.xml
index 186d89a51..b0d1afe97 100644
--- a/benchmark/pom.xml
+++ b/benchmark/pom.xml
@@ -6,7 +6,7 @@
google-cloud-bigquery-parent
com.google.cloud
- 2.11.2
+ 2.12.0
diff --git a/google-cloud-bigquery/pom.xml b/google-cloud-bigquery/pom.xml
index 049beb224..1736ade47 100644
--- a/google-cloud-bigquery/pom.xml
+++ b/google-cloud-bigquery/pom.xml
@@ -3,7 +3,7 @@
4.0.0
com.google.cloud
google-cloud-bigquery
- 2.11.2
+ 2.12.0
jar
BigQuery
https://github.com/googleapis/java-bigquery
@@ -11,7 +11,7 @@
com.google.cloud
google-cloud-bigquery-parent
- 2.11.2
+ 2.12.0
google-cloud-bigquery
diff --git a/google-cloud-bigquery/src/main/resources/META-INF/native-image/com.google.cloud/google-cloud-bigquery/reflect-config.json b/google-cloud-bigquery/src/main/resources/META-INF/native-image/com.google.cloud/google-cloud-bigquery/reflect-config.json
index f2190122d..8f6d928da 100644
--- a/google-cloud-bigquery/src/main/resources/META-INF/native-image/com.google.cloud/google-cloud-bigquery/reflect-config.json
+++ b/google-cloud-bigquery/src/main/resources/META-INF/native-image/com.google.cloud/google-cloud-bigquery/reflect-config.json
@@ -3,8 +3,67 @@
"name":"io.netty.buffer.AbstractByteBufAllocator",
"queryAllDeclaredMethods":true
},
+ {
+ "name":"io.netty.buffer.PooledByteBufAllocator",
+ "fields":[{"name":"directArenas"}]
+ },
+ {
+ "name":"io.netty.util.internal.shaded.org.jctools.queues.MpscChunkedArrayQueue",
+ "queryAllDeclaredMethods":true,
+ "allDeclaredFields":true,
+ "queryAllDeclaredConstructors":true
+ },
+ {
+ "name":"io.netty.util.internal.shaded.org.jctools.queues.MpscArrayQueueConsumerIndexField",
+ "fields":[{"name":"consumerIndex"}]
+ },
+ {
+ "name":"io.netty.util.internal.shaded.org.jctools.queues.MpscArrayQueueProducerIndexField",
+ "fields":[{"name":"producerIndex"}]
+ },
+ {
+ "name":"io.netty.util.internal.shaded.org.jctools.queues.MpscArrayQueueProducerLimitField",
+ "fields":[{"name":"producerLimit"}]
+ },
+ {
+ "name":"java.nio.DirectByteBuffer",
+ "methods":[{"name":"","parameterTypes":["long","int"] }]
+ },
{
"name":"org.apache.arrow.memory.DefaultAllocationManagerFactory",
"fields":[{"name":"FACTORY"}]
+ },
+ {
+ "name":"org.apache.arrow.vector.types.pojo.ArrowType",
+ "allDeclaredFields":true,
+ "queryAllDeclaredMethods":true,
+ "queryAllDeclaredConstructors":true
+ },
+ {
+ "name":"org.apache.arrow.vector.types.pojo.ArrowType$Int",
+ "allDeclaredFields":true,
+ "queryAllDeclaredMethods":true,
+ "queryAllDeclaredConstructors":true
+ },
+ {
+ "name":"org.apache.arrow.vector.types.pojo.ArrowType$PrimitiveType",
+ "allDeclaredFields":true,
+ "queryAllDeclaredMethods":true
+ },
+ {
+ "name":"io.netty.buffer.AbstractReferenceCountedByteBuf",
+ "fields":[{"name":"refCnt"}]
+ },
+ {
+ "name":"io.netty.util.internal.shaded.org.jctools.queues.BaseMpscLinkedArrayQueueColdProducerFields",
+ "fields":[{"name":"producerLimit"}]
+ },
+ {
+ "name":"io.netty.util.internal.shaded.org.jctools.queues.BaseMpscLinkedArrayQueueConsumerFields",
+ "fields":[{"name":"consumerIndex"}]
+ },
+ {
+ "name":"io.netty.util.internal.shaded.org.jctools.queues.BaseMpscLinkedArrayQueueProducerFields",
+ "fields":[{"name":"producerIndex"}]
}
]
\ No newline at end of file
diff --git a/google-cloud-bigquery/src/test/java/com/google/cloud/bigquery/it/ITBigQueryTest.java b/google-cloud-bigquery/src/test/java/com/google/cloud/bigquery/it/ITBigQueryTest.java
index dcfa5265f..5b2b74ec0 100644
--- a/google-cloud-bigquery/src/test/java/com/google/cloud/bigquery/it/ITBigQueryTest.java
+++ b/google-cloud-bigquery/src/test/java/com/google/cloud/bigquery/it/ITBigQueryTest.java
@@ -3438,7 +3438,12 @@ public void testPositionalQueryParameters() throws InterruptedException {
assertEquals(QUERY_RESULT_SCHEMA_BIGNUMERIC, result.getSchema());
assertEquals(2, Iterables.size(result.getValues()));
for (FieldValueList values : result.iterateAll()) {
- assertEquals("1.40845209522E9", values.get(0).getValue());
+ // https://github.com/googleapis/java-bigquery/issues/2056. String comparison of values, eg
+ // 1.40845209522E9 vs 1408452095.22 seems to be failing, so comparing the values as epoc
+ // (Long) instead
+ assertEquals(
+ (long) Double.parseDouble("1.40845209522E9"),
+ (long) Double.parseDouble(values.get(0).getValue().toString()));
assertEquals("stringValue", values.get(1).getValue());
assertEquals(false, values.get(2).getBooleanValue());
assertEquals("0.33333333333333333333333333333333333333", values.get(3).getValue());
diff --git a/owlbot.py b/owlbot.py
index 55f7f4101..54ebff861 100644
--- a/owlbot.py
+++ b/owlbot.py
@@ -22,5 +22,5 @@
'.kokoro/dependencies.sh',
'codecov.yaml',
'renovate.json',
- '.kokoro/build.sh',
+ '.kokoro/build.sh'
])
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index bae36ea40..05a6ce473 100644
--- a/pom.xml
+++ b/pom.xml
@@ -4,7 +4,7 @@
com.google.cloud
google-cloud-bigquery-parent
pom
- 2.11.2
+ 2.12.0
BigQuery Parent
https://github.com/googleapis/java-bigquery
@@ -54,7 +54,7 @@
github
google-cloud-bigquery-parent
v2-rev20220507-1.32.1
- 2.10.0
+ 2.12.0
8.0.0
@@ -72,7 +72,7 @@
com.google.cloud
google-cloud-bigquerystorage-bom
- 2.13.0
+ 2.14.0
pom
import
@@ -118,7 +118,7 @@
com.google.cloud
google-cloud-bigquery
- 2.11.2
+ 2.12.0
@@ -176,7 +176,7 @@
com.google.cloud
google-cloud-storage
- 2.6.1
+ 2.7.1
test
diff --git a/samples/install-without-bom/pom.xml b/samples/install-without-bom/pom.xml
index 906f422e0..55cedc650 100644
--- a/samples/install-without-bom/pom.xml
+++ b/samples/install-without-bom/pom.xml
@@ -45,7 +45,7 @@
com.google.cloud
google-cloud-bigquery
- 2.11.1
+ 2.11.2
@@ -63,13 +63,13 @@
com.google.cloud
google-cloud-bigtable
- 2.6.2
+ 2.7.0
test
com.google.cloud
google-cloud-bigqueryconnection
- 2.2.4
+ 2.3.0
test
diff --git a/samples/snapshot/pom.xml b/samples/snapshot/pom.xml
index 0c3597967..a6c2f4398 100644
--- a/samples/snapshot/pom.xml
+++ b/samples/snapshot/pom.xml
@@ -44,7 +44,7 @@
com.google.cloud
google-cloud-bigquery
- 2.11.2
+ 2.12.0
@@ -61,13 +61,13 @@
com.google.cloud
google-cloud-bigtable
- 2.6.2
+ 2.7.0
test
com.google.cloud
google-cloud-bigqueryconnection
- 2.2.4
+ 2.3.0
test
diff --git a/samples/snippets/pom.xml b/samples/snippets/pom.xml
index 1e8dd6ef9..821f95718 100644
--- a/samples/snippets/pom.xml
+++ b/samples/snippets/pom.xml
@@ -79,13 +79,13 @@
com.google.cloud
google-cloud-bigtable
- 2.6.2
+ 2.7.0
test
com.google.cloud
google-cloud-bigqueryconnection
- 2.2.4
+ 2.3.0
test
diff --git a/versions.txt b/versions.txt
index 503185ac7..026fbb39e 100644
--- a/versions.txt
+++ b/versions.txt
@@ -1,4 +1,4 @@
# Format:
# module:released-version:current-version
-google-cloud-bigquery:2.11.2:2.11.2
\ No newline at end of file
+google-cloud-bigquery:2.12.0:2.12.0
\ No newline at end of file