From 8caa0726e43cb2d111adb21c83e3c34e8683777a Mon Sep 17 00:00:00 2001 From: Jin Seop Kim Date: Wed, 29 Jul 2026 10:30:04 -0400 Subject: [PATCH 1/6] feat(bigquery): add QueryResultsFormat and ArrowSerializationOptions configurations --- google-cloud-jar-parent/pom.xml | 2 +- .../bigquery/ArrowSerializationOptions.java | 118 ++++++++++++++++++ .../cloud/bigquery/QueryJobConfiguration.java | 47 ++++++- .../cloud/bigquery/QueryResultsFormat.java | 29 +++++ .../bigquery/QueryJobConfigurationTest.java | 29 +++++ 5 files changed, 220 insertions(+), 5 deletions(-) create mode 100644 java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java create mode 100644 java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryResultsFormat.java diff --git a/google-cloud-jar-parent/pom.xml b/google-cloud-jar-parent/pom.xml index b1e26861cab0..1f30f4f224e6 100644 --- a/google-cloud-jar-parent/pom.xml +++ b/google-cloud-jar-parent/pom.xml @@ -142,7 +142,7 @@ com.google.apis google-api-services-bigquery - v2-rev20260612-2.0.0 + v2-rev20260707-2.0.0 diff --git a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java new file mode 100644 index 000000000000..457ea4917daf --- /dev/null +++ b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java @@ -0,0 +1,118 @@ +/* + * Copyright 2026 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.bigquery; + +import com.google.api.core.BetaApi; +import java.io.Serializable; +import java.util.Objects; + +/** Options specific to the Apache Arrow output format. */ +@BetaApi +public final class ArrowSerializationOptions implements Serializable { + + private static final long serialVersionUID = 1L; + + private final String bufferCompression; + private final String picosTimestampPrecision; + + private ArrowSerializationOptions(Builder builder) { + this.bufferCompression = builder.bufferCompression; + this.picosTimestampPrecision = builder.picosTimestampPrecision; + } + + public String getBufferCompression() { + return bufferCompression; + } + + public String getPicosTimestampPrecision() { + return picosTimestampPrecision; + } + + public static Builder newBuilder() { + return new Builder(); + } + + @Override + public String toString() { + return com.google.common.base.MoreObjects.toStringHelper(this) + .add("bufferCompression", bufferCompression) + .add("picosTimestampPrecision", picosTimestampPrecision) + .toString(); + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ArrowSerializationOptions that = (ArrowSerializationOptions) o; + return Objects.equals(bufferCompression, that.bufferCompression) + && Objects.equals(picosTimestampPrecision, that.picosTimestampPrecision); + } + + @Override + public int hashCode() { + return Objects.hash(bufferCompression, picosTimestampPrecision); + } + + com.google.api.services.bigquery.model.ArrowSerializationOptions toPb() { + com.google.api.services.bigquery.model.ArrowSerializationOptions optionsPb = + new com.google.api.services.bigquery.model.ArrowSerializationOptions(); + if (bufferCompression != null) { + optionsPb.setBufferCompression(bufferCompression); + } + if (picosTimestampPrecision != null) { + optionsPb.setPicosTimestampPrecision(picosTimestampPrecision); + } + return optionsPb; + } + + static ArrowSerializationOptions fromPb( + com.google.api.services.bigquery.model.ArrowSerializationOptions optionsPb) { + if (optionsPb == null) { + return null; + } + return newBuilder() + .setBufferCompression(optionsPb.getBufferCompression()) + .setPicosTimestampPrecision(optionsPb.getPicosTimestampPrecision()) + .build(); + } + + public static final class Builder { + private String bufferCompression; + private String picosTimestampPrecision; + + private Builder() {} + + public Builder setBufferCompression(String bufferCompression) { + this.bufferCompression = bufferCompression; + return this; + } + + public Builder setPicosTimestampPrecision(String picosTimestampPrecision) { + this.picosTimestampPrecision = picosTimestampPrecision; + return this; + } + + public ArrowSerializationOptions build() { + return new ArrowSerializationOptions(this); + } + } +} diff --git a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryJobConfiguration.java b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryJobConfiguration.java index a62fbb5008d4..0d75d509d1a3 100644 --- a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryJobConfiguration.java +++ b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryJobConfiguration.java @@ -75,6 +75,8 @@ public final class QueryJobConfiguration extends JobConfiguration { private final Long maxResults; private final JobCreationMode jobCreationMode; private final String reservation; + private final QueryResultsFormat queryResultsFormat; + private final ArrowSerializationOptions arrowSerializationOptions; /** * Priority levels for a query. If not specified the priority is assumed to be {@link @@ -144,6 +146,8 @@ public static final class Builder private Long maxResults; private JobCreationMode jobCreationMode; private String reservation; + private QueryResultsFormat queryResultsFormat; + private ArrowSerializationOptions arrowSerializationOptions; private Builder() { super(Type.QUERY); @@ -181,6 +185,8 @@ private Builder(QueryJobConfiguration jobConfiguration) { this.maxResults = jobConfiguration.maxResults; this.jobCreationMode = jobConfiguration.jobCreationMode; this.reservation = jobConfiguration.reservation; + this.queryResultsFormat = jobConfiguration.queryResultsFormat; + this.arrowSerializationOptions = jobConfiguration.arrowSerializationOptions; } private Builder(com.google.api.services.bigquery.model.JobConfiguration configurationPb) { @@ -701,6 +707,17 @@ public Builder setReservation(String reservation) { return this; } + public Builder setQueryResultsFormat(QueryResultsFormat queryResultsFormat) { + this.queryResultsFormat = queryResultsFormat; + return this; + } + + public Builder setArrowSerializationOptions( + ArrowSerializationOptions arrowSerializationOptions) { + this.arrowSerializationOptions = arrowSerializationOptions; + return this; + } + public QueryJobConfiguration build() { return new QueryJobConfiguration(this); } @@ -747,6 +764,8 @@ private QueryJobConfiguration(Builder builder) { this.maxResults = builder.maxResults; this.jobCreationMode = builder.jobCreationMode; this.reservation = builder.reservation; + this.queryResultsFormat = builder.queryResultsFormat; + this.arrowSerializationOptions = builder.arrowSerializationOptions; } /** @@ -973,6 +992,14 @@ public Builder toBuilder() { return new Builder(this); } + public QueryResultsFormat getQueryResultsFormat() { + return queryResultsFormat; + } + + public ArrowSerializationOptions getArrowSerializationOptions() { + return arrowSerializationOptions; + } + @Override ToStringHelper toStringHelper() { return super.toStringHelper() @@ -1004,13 +1031,23 @@ ToStringHelper toStringHelper() { .add("rangePartitioning", rangePartitioning) .add("connectionProperties", connectionProperties) .add("jobCreationMode", jobCreationMode) - .add("reservation", reservation); + .add("reservation", reservation) + .add("queryResultsFormat", queryResultsFormat) + .add("arrowSerializationOptions", arrowSerializationOptions); } @Override public boolean equals(Object obj) { - return obj == this - || obj instanceof QueryJobConfiguration && baseEquals((QueryJobConfiguration) obj); + if (obj == this) { + return true; + } + if (obj == null || !(obj instanceof QueryJobConfiguration)) { + return false; + } + QueryJobConfiguration other = (QueryJobConfiguration) obj; + return baseEquals(other) + && Objects.equals(queryResultsFormat, other.queryResultsFormat) + && Objects.equals(arrowSerializationOptions, other.arrowSerializationOptions); } @Override @@ -1043,7 +1080,9 @@ public int hashCode() { labels, rangePartitioning, connectionProperties, - reservation); + reservation, + queryResultsFormat, + arrowSerializationOptions); } @Override diff --git a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryResultsFormat.java b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryResultsFormat.java new file mode 100644 index 000000000000..61c12d34e326 --- /dev/null +++ b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryResultsFormat.java @@ -0,0 +1,29 @@ +/* + * Copyright 2026 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.bigquery; + +import com.google.api.core.BetaApi; + +/** The format of the query results. */ +@BetaApi +public enum QueryResultsFormat { + /** Serialized row data in Apache Arrow format. */ + ARROW, + + /** Default encoding of results as JSON struct array. */ + STRUCT_ENCODING +} diff --git a/java-bigquery/google-cloud-bigquery/src/test/java/com/google/cloud/bigquery/QueryJobConfigurationTest.java b/java-bigquery/google-cloud-bigquery/src/test/java/com/google/cloud/bigquery/QueryJobConfigurationTest.java index 7fe41daa0608..1d60d904bfab 100644 --- a/java-bigquery/google-cloud-bigquery/src/test/java/com/google/cloud/bigquery/QueryJobConfigurationTest.java +++ b/java-bigquery/google-cloud-bigquery/src/test/java/com/google/cloud/bigquery/QueryJobConfigurationTest.java @@ -241,6 +241,35 @@ public void testJobCreationMode() { QUERY_JOB_CONFIGURATION_SET_JOB_CREATION_MODE.toBuilder().build()); } + @Test + public void testArrowConfigurations() { + QueryResultsFormat format = QueryResultsFormat.ARROW; + ArrowSerializationOptions options = + ArrowSerializationOptions.newBuilder() + .setBufferCompression("LZ4") + .setPicosTimestampPrecision("PRECISION_MILLIS") + .build(); + QueryJobConfiguration job = + QueryJobConfiguration.newBuilder(QUERY) + .setQueryResultsFormat(format) + .setArrowSerializationOptions(options) + .build(); + + assertEquals(format, job.getQueryResultsFormat()); + assertEquals(options, job.getArrowSerializationOptions()); + + // Test toBuilder + QueryJobConfiguration copiedJob = job.toBuilder().build(); + assertEquals(job, copiedJob); + assertEquals(format, copiedJob.getQueryResultsFormat()); + assertEquals(options, copiedJob.getArrowSerializationOptions()); + + // Test toPb/fromPb (not preserved) + QueryJobConfiguration jobFromPb = QueryJobConfiguration.fromPb(job.toPb()); + assertNull(jobFromPb.getQueryResultsFormat()); + assertNull(jobFromPb.getArrowSerializationOptions()); + } + private void compareQueryJobConfiguration( QueryJobConfiguration expected, QueryJobConfiguration value) { assertEquals(expected, value); From b441a9dfbf02afebeb96b1ebc3bc51f5eec95b16 Mon Sep 17 00:00:00 2001 From: Jin Seop Kim Date: Fri, 7 Aug 2026 12:09:05 -0400 Subject: [PATCH 2/6] docs(bigquery): add prerequisite and behavior Javadoc for QueryResultsFormat setters --- .../cloud/bigquery/QueryJobConfiguration.java | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryJobConfiguration.java b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryJobConfiguration.java index 0d75d509d1a3..414dae6d3ab4 100644 --- a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryJobConfiguration.java +++ b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/QueryJobConfiguration.java @@ -707,11 +707,34 @@ public Builder setReservation(String reservation) { return this; } + /** + * Sets the query results response format. Defaults to {@link + * QueryResultsFormat#STRUCT_ENCODING}. + * + *

When set to {@link QueryResultsFormat#ARROW}, query results are returned in binary Apache + * Arrow format, utilizing gRPC Storage Read streams for subsequent pages. + * + *

Prerequisite: Requires the BigQuery Storage Read API ({@code + * bigquerystorage.googleapis.com}) to be enabled on your GCP project and your credentials to + * have Storage Read permissions (e.g. {@code bigquery.readsessions.create}). + * + * @param queryResultsFormat the format for query result payloads + * @return the Builder + */ public Builder setQueryResultsFormat(QueryResultsFormat queryResultsFormat) { this.queryResultsFormat = queryResultsFormat; return this; } + /** + * Sets Arrow serialization options. Defaults to null. + * + *

Note: Only applied in the request payload when {@code queryResultsFormat} is {@code + * ARROW}. + * + * @param arrowSerializationOptions the Arrow serialization options to set + * @return the Builder + */ public Builder setArrowSerializationOptions( ArrowSerializationOptions arrowSerializationOptions) { this.arrowSerializationOptions = arrowSerializationOptions; From 13a7e67ad1dbe80d31abd9ba9827d964fca5ba12 Mon Sep 17 00:00:00 2001 From: Jin Seop Kim Date: Fri, 7 Aug 2026 15:48:16 -0400 Subject: [PATCH 3/6] refactor(bigquery): replace fully qualified MoreObjects path with simple import --- .../com/google/cloud/bigquery/ArrowSerializationOptions.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java index 457ea4917daf..3eb611564877 100644 --- a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java +++ b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java @@ -17,6 +17,7 @@ package com.google.cloud.bigquery; import com.google.api.core.BetaApi; +import com.google.common.base.MoreObjects; import java.io.Serializable; import java.util.Objects; @@ -48,7 +49,7 @@ public static Builder newBuilder() { @Override public String toString() { - return com.google.common.base.MoreObjects.toStringHelper(this) + return MoreObjects.toStringHelper(this) .add("bufferCompression", bufferCompression) .add("picosTimestampPrecision", picosTimestampPrecision) .toString(); From afc995181291206e0a66bd50601ca82f5b74bfb8 Mon Sep 17 00:00:00 2001 From: Jin Seop Kim Date: Fri, 7 Aug 2026 15:53:32 -0400 Subject: [PATCH 4/6] refactor(bigquery): eliminate FQCN in ArrowSerializationOptions via converter helper --- .../bigquery/ArrowSerializationOptions.java | 20 ++------ .../ArrowSerializationOptionsConverter.java | 50 +++++++++++++++++++ 2 files changed, 53 insertions(+), 17 deletions(-) create mode 100644 java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptionsConverter.java diff --git a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java index 3eb611564877..812ec12e7e30 100644 --- a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java +++ b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java @@ -73,27 +73,13 @@ public int hashCode() { return Objects.hash(bufferCompression, picosTimestampPrecision); } - com.google.api.services.bigquery.model.ArrowSerializationOptions toPb() { - com.google.api.services.bigquery.model.ArrowSerializationOptions optionsPb = - new com.google.api.services.bigquery.model.ArrowSerializationOptions(); - if (bufferCompression != null) { - optionsPb.setBufferCompression(bufferCompression); - } - if (picosTimestampPrecision != null) { - optionsPb.setPicosTimestampPrecision(picosTimestampPrecision); - } - return optionsPb; + Object toPb() { + return ArrowSerializationOptionsConverter.toPb(this); } static ArrowSerializationOptions fromPb( com.google.api.services.bigquery.model.ArrowSerializationOptions optionsPb) { - if (optionsPb == null) { - return null; - } - return newBuilder() - .setBufferCompression(optionsPb.getBufferCompression()) - .setPicosTimestampPrecision(optionsPb.getPicosTimestampPrecision()) - .build(); + return ArrowSerializationOptionsConverter.fromPb(optionsPb); } public static final class Builder { diff --git a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptionsConverter.java b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptionsConverter.java new file mode 100644 index 000000000000..6b827acd96c6 --- /dev/null +++ b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptionsConverter.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.bigquery; + +import com.google.api.services.bigquery.model.ArrowSerializationOptions; + +final class ArrowSerializationOptionsConverter { + + private ArrowSerializationOptionsConverter() {} + + static ArrowSerializationOptions toPb( + com.google.cloud.bigquery.ArrowSerializationOptions options) { + if (options == null) { + return null; + } + ArrowSerializationOptions optionsPb = new ArrowSerializationOptions(); + if (options.getBufferCompression() != null) { + optionsPb.setBufferCompression(options.getBufferCompression()); + } + if (options.getPicosTimestampPrecision() != null) { + optionsPb.setPicosTimestampPrecision(options.getPicosTimestampPrecision()); + } + return optionsPb; + } + + static com.google.cloud.bigquery.ArrowSerializationOptions fromPb( + ArrowSerializationOptions optionsPb) { + if (optionsPb == null) { + return null; + } + return com.google.cloud.bigquery.ArrowSerializationOptions.newBuilder() + .setBufferCompression(optionsPb.getBufferCompression()) + .setPicosTimestampPrecision(optionsPb.getPicosTimestampPrecision()) + .build(); + } +} From 8f551c7329b40717401efecf0cb4555d94cf9cee Mon Sep 17 00:00:00 2001 From: Jin Seop Kim Date: Fri, 7 Aug 2026 15:58:00 -0400 Subject: [PATCH 5/6] refactor(bigquery): return model ArrowSerializationOptions in toPb --- .../com/google/cloud/bigquery/ArrowSerializationOptions.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java index 812ec12e7e30..1ad88f8de84b 100644 --- a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java +++ b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptions.java @@ -73,7 +73,7 @@ public int hashCode() { return Objects.hash(bufferCompression, picosTimestampPrecision); } - Object toPb() { + com.google.api.services.bigquery.model.ArrowSerializationOptions toPb() { return ArrowSerializationOptionsConverter.toPb(this); } From 30f68359a01399720b64ac31b3cbac647b173350 Mon Sep 17 00:00:00 2001 From: Jin Seop Kim Date: Fri, 7 Aug 2026 16:26:13 -0400 Subject: [PATCH 6/6] refactor(bigquery): eliminate FQCN in ArrowSerializationOptions and ArrowSerializationOptionsConverter --- .../ArrowSerializationOptionsConverter.java | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptionsConverter.java b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptionsConverter.java index 6b827acd96c6..fc7b4bb1d419 100644 --- a/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptionsConverter.java +++ b/java-bigquery/google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/ArrowSerializationOptionsConverter.java @@ -16,18 +16,17 @@ package com.google.cloud.bigquery; -import com.google.api.services.bigquery.model.ArrowSerializationOptions; - final class ArrowSerializationOptionsConverter { private ArrowSerializationOptionsConverter() {} - static ArrowSerializationOptions toPb( - com.google.cloud.bigquery.ArrowSerializationOptions options) { + static com.google.api.services.bigquery.model.ArrowSerializationOptions toPb( + ArrowSerializationOptions options) { if (options == null) { return null; } - ArrowSerializationOptions optionsPb = new ArrowSerializationOptions(); + com.google.api.services.bigquery.model.ArrowSerializationOptions optionsPb = + new com.google.api.services.bigquery.model.ArrowSerializationOptions(); if (options.getBufferCompression() != null) { optionsPb.setBufferCompression(options.getBufferCompression()); } @@ -37,12 +36,13 @@ static ArrowSerializationOptions toPb( return optionsPb; } - static com.google.cloud.bigquery.ArrowSerializationOptions fromPb( - ArrowSerializationOptions optionsPb) { - if (optionsPb == null) { + static ArrowSerializationOptions fromPb(Object optionsPbObj) { + if (optionsPbObj == null) { return null; } - return com.google.cloud.bigquery.ArrowSerializationOptions.newBuilder() + com.google.api.services.bigquery.model.ArrowSerializationOptions optionsPb = + (com.google.api.services.bigquery.model.ArrowSerializationOptions) optionsPbObj; + return ArrowSerializationOptions.newBuilder() .setBufferCompression(optionsPb.getBufferCompression()) .setPicosTimestampPrecision(optionsPb.getPicosTimestampPrecision()) .build();