diff --git a/README.md b/README.md
index fc1006eb5ab..3b2c43bd442 100644
--- a/README.md
+++ b/README.md
@@ -50,7 +50,7 @@ If you are using Maven without the BOM, add this to your dependencies:
If you are using Gradle 5.x or later, add this to your dependencies:
```Groovy
-implementation platform('com.google.cloud:libraries-bom:26.28.0')
+implementation platform('com.google.cloud:libraries-bom:26.29.0')
implementation 'com.google.cloud:google-cloud-spanner'
```
diff --git a/google-cloud-spanner-executor/pom.xml b/google-cloud-spanner-executor/pom.xml
index f9325e8f49d..eab274a3a6f 100644
--- a/google-cloud-spanner-executor/pom.xml
+++ b/google-cloud-spanner-executor/pom.xml
@@ -34,6 +34,10 @@
This class provides the ability to make remote calls to the backing service through method + * calls that map to API methods. Sample code to get started: + * + *
{@code + * // This snippet has been automatically generated and should be regarded as a code template only. + * // It will require modifications to work: + * // - It may require correct/in-range values for request initialization. + * // - It may require specifying regional endpoints when creating the service client as shown in + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + * try (SpannerExecutorProxyClient spannerExecutorProxyClient = + * SpannerExecutorProxyClient.create()) { + * BidiStream+ * + *bidiStream = + * spannerExecutorProxyClient.executeActionAsyncCallable().call(); + * SpannerAsyncActionRequest request = + * SpannerAsyncActionRequest.newBuilder() + * .setActionId(198295492) + * .setAction(SpannerAction.newBuilder().build()) + * .build(); + * bidiStream.send(request); + * for (SpannerAsyncActionResponse response : bidiStream) { + * // Do something when a response is received. + * } + * } + * }
Note: close() needs to be called on the SpannerExecutorProxyClient object to clean up + * resources such as threads. In the example above, try-with-resources is used, which automatically + * calls close(). + * + *
The surface of this class includes several types of Java methods for each of the API's + * methods: + * + *
See the individual methods for example code. + * + *
Many parameters require resource names to be formatted in a particular way. To assist with + * these names, this class includes a format method for each type of name, and additionally a parse + * method to extract the individual identifiers contained within names that are returned. + * + *
This class can be customized by passing in a custom instance of SpannerExecutorProxySettings + * to create(). For example: + * + *
To customize credentials: + * + *
{@code + * // This snippet has been automatically generated and should be regarded as a code template only. + * // It will require modifications to work: + * // - It may require correct/in-range values for request initialization. + * // - It may require specifying regional endpoints when creating the service client as shown in + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + * SpannerExecutorProxySettings spannerExecutorProxySettings = + * SpannerExecutorProxySettings.newBuilder() + * .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials)) + * .build(); + * SpannerExecutorProxyClient spannerExecutorProxyClient = + * SpannerExecutorProxyClient.create(spannerExecutorProxySettings); + * }+ * + *
To customize the endpoint: + * + *
{@code + * // This snippet has been automatically generated and should be regarded as a code template only. + * // It will require modifications to work: + * // - It may require correct/in-range values for request initialization. + * // - It may require specifying regional endpoints when creating the service client as shown in + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + * SpannerExecutorProxySettings spannerExecutorProxySettings = + * SpannerExecutorProxySettings.newBuilder().setEndpoint(myEndpoint).build(); + * SpannerExecutorProxyClient spannerExecutorProxyClient = + * SpannerExecutorProxyClient.create(spannerExecutorProxySettings); + * }+ * + *
Please refer to the GitHub repository's samples for more quickstart code snippets. + */ +@Generated("by gapic-generator-java") +public class SpannerExecutorProxyClient implements BackgroundResource { + private final SpannerExecutorProxySettings settings; + private final SpannerExecutorProxyStub stub; + + /** Constructs an instance of SpannerExecutorProxyClient with default settings. */ + public static final SpannerExecutorProxyClient create() throws IOException { + return create(SpannerExecutorProxySettings.newBuilder().build()); + } + + /** + * Constructs an instance of SpannerExecutorProxyClient, using the given settings. The channels + * are created based on the settings passed in, or defaults for any settings that are not set. + */ + public static final SpannerExecutorProxyClient create(SpannerExecutorProxySettings settings) + throws IOException { + return new SpannerExecutorProxyClient(settings); + } + + /** + * Constructs an instance of SpannerExecutorProxyClient, using the given stub for making calls. + * This is for advanced usage - prefer using create(SpannerExecutorProxySettings). + */ + public static final SpannerExecutorProxyClient create(SpannerExecutorProxyStub stub) { + return new SpannerExecutorProxyClient(stub); + } + + /** + * Constructs an instance of SpannerExecutorProxyClient, using the given settings. This is + * protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected SpannerExecutorProxyClient(SpannerExecutorProxySettings settings) throws IOException { + this.settings = settings; + this.stub = ((SpannerExecutorProxyStubSettings) settings.getStubSettings()).createStub(); + } + + protected SpannerExecutorProxyClient(SpannerExecutorProxyStub stub) { + this.settings = null; + this.stub = stub; + } + + public final SpannerExecutorProxySettings getSettings() { + return settings; + } + + public SpannerExecutorProxyStub getStub() { + return stub; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * ExecuteActionAsync is a streaming call that starts executing a new Spanner action. + * + *
For each request, the server will reply with one or more responses, but only the last + * response will contain status in the outcome. + * + *
Responses can be matched to requests by action_id. It is allowed to have multiple actions in + * flight--in that case, actions are be executed in parallel. + * + *
Sample code: + * + *
{@code + * // This snippet has been automatically generated and should be regarded as a code template only. + * // It will require modifications to work: + * // - It may require correct/in-range values for request initialization. + * // - It may require specifying regional endpoints when creating the service client as shown in + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + * try (SpannerExecutorProxyClient spannerExecutorProxyClient = + * SpannerExecutorProxyClient.create()) { + * BidiStream+ */ + public final BidiStreamingCallablebidiStream = + * spannerExecutorProxyClient.executeActionAsyncCallable().call(); + * SpannerAsyncActionRequest request = + * SpannerAsyncActionRequest.newBuilder() + * .setActionId(198295492) + * .setAction(SpannerAction.newBuilder().build()) + * .build(); + * bidiStream.send(request); + * for (SpannerAsyncActionResponse response : bidiStream) { + * // Do something when a response is received. + * } + * } + * }
The default instance has everything set to sensible defaults: + * + *
The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. + * + *
For example, to set the total timeout of executeActionAsync to 30 seconds: + * + *
{@code + * // This snippet has been automatically generated and should be regarded as a code template only. + * // It will require modifications to work: + * // - It may require correct/in-range values for request initialization. + * // - It may require specifying regional endpoints when creating the service client as shown in + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + * SpannerExecutorProxySettings.Builder spannerExecutorProxySettingsBuilder = + * SpannerExecutorProxySettings.newBuilder(); + * spannerExecutorProxySettingsBuilder + * .executeActionAsyncSettings() + * .setRetrySettings( + * spannerExecutorProxySettingsBuilder + * .executeActionAsyncSettings() + * .getRetrySettings() + * .toBuilder() + * .setTotalTimeout(Duration.ofSeconds(30)) + * .build()); + * SpannerExecutorProxySettings spannerExecutorProxySettings = + * spannerExecutorProxySettingsBuilder.build(); + * }+ */ +@Generated("by gapic-generator-java") +public class SpannerExecutorProxySettings extends ClientSettings
Note: This method does not support applying settings to streaming methods.
+ */
+ public Builder applyToAllUnaryMethods(
+ ApiFunction The interfaces provided are listed below, along with usage samples.
+ *
+ * ======================= SpannerExecutorProxyClient =======================
+ *
+ * Service Description: Service that executes SpannerActions asynchronously.
+ *
+ * Sample for SpannerExecutorProxyClient:
+ *
+ * This class is for advanced usage.
+ */
+@Generated("by gapic-generator-java")
+public class GrpcSpannerExecutorProxyCallableFactory implements GrpcStubCallableFactory {
+
+ @Override
+ public This class is for advanced usage and reflects the underlying API directly.
+ */
+@Generated("by gapic-generator-java")
+public class GrpcSpannerExecutorProxyStub extends SpannerExecutorProxyStub {
+ private static final MethodDescriptor This class is for advanced usage and reflects the underlying API directly.
+ */
+@Generated("by gapic-generator-java")
+public abstract class SpannerExecutorProxyStub implements BackgroundResource {
+
+ public BidiStreamingCallable The default instance has everything set to sensible defaults:
+ *
+ * The builder of this class is recursive, so contained classes are themselves builders. When
+ * build() is called, the tree of builders is called to create the complete settings object.
+ *
+ * For example, to set the total timeout of executeActionAsync to 30 seconds:
+ *
+ * Note: This method does not support applying settings to streaming methods.
+ */
+ public Builder applyToAllUnaryMethods(
+ ApiFunction{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * try (SpannerExecutorProxyClient spannerExecutorProxyClient =
+ * SpannerExecutorProxyClient.create()) {
+ * BidiStream
+ */
+@Generated("by gapic-generator-java")
+package com.google.cloud.spanner.executor.v1;
+
+import javax.annotation.Generated;
diff --git a/google-cloud-spanner-executor/src/main/java/com/google/cloud/spanner/executor/v1/stub/GrpcSpannerExecutorProxyCallableFactory.java b/google-cloud-spanner-executor/src/main/java/com/google/cloud/spanner/executor/v1/stub/GrpcSpannerExecutorProxyCallableFactory.java
new file mode 100644
index 00000000000..e890b9d400d
--- /dev/null
+++ b/google-cloud-spanner-executor/src/main/java/com/google/cloud/spanner/executor/v1/stub/GrpcSpannerExecutorProxyCallableFactory.java
@@ -0,0 +1,113 @@
+/*
+ * Copyright 2023 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
+ *
+ * https://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.spanner.executor.v1.stub;
+
+import com.google.api.gax.grpc.GrpcCallSettings;
+import com.google.api.gax.grpc.GrpcCallableFactory;
+import com.google.api.gax.grpc.GrpcStubCallableFactory;
+import com.google.api.gax.rpc.BatchingCallSettings;
+import com.google.api.gax.rpc.BidiStreamingCallable;
+import com.google.api.gax.rpc.ClientContext;
+import com.google.api.gax.rpc.ClientStreamingCallable;
+import com.google.api.gax.rpc.OperationCallSettings;
+import com.google.api.gax.rpc.OperationCallable;
+import com.google.api.gax.rpc.PagedCallSettings;
+import com.google.api.gax.rpc.ServerStreamingCallSettings;
+import com.google.api.gax.rpc.ServerStreamingCallable;
+import com.google.api.gax.rpc.StreamingCallSettings;
+import com.google.api.gax.rpc.UnaryCallSettings;
+import com.google.api.gax.rpc.UnaryCallable;
+import com.google.longrunning.Operation;
+import com.google.longrunning.stub.OperationsStub;
+import javax.annotation.Generated;
+
+// AUTO-GENERATED DOCUMENTATION AND CLASS.
+/**
+ * gRPC callable factory implementation for the SpannerExecutorProxy service API.
+ *
+ *
+ *
+ *
+ * {@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * SpannerExecutorProxyStubSettings.Builder spannerExecutorProxySettingsBuilder =
+ * SpannerExecutorProxyStubSettings.newBuilder();
+ * spannerExecutorProxySettingsBuilder
+ * .executeActionAsyncSettings()
+ * .setRetrySettings(
+ * spannerExecutorProxySettingsBuilder
+ * .executeActionAsyncSettings()
+ * .getRetrySettings()
+ * .toBuilder()
+ * .setTotalTimeout(Duration.ofSeconds(30))
+ * .build());
+ * SpannerExecutorProxyStubSettings spannerExecutorProxySettings =
+ * spannerExecutorProxySettingsBuilder.build();
+ * }
+ */
+@Generated("by gapic-generator-java")
+public class SpannerExecutorProxyStubSettings
+ extends StubSettings