Skip to content

Commit 3d72154

Browse files
yoshi-automationsduskis
authored andcommitted
---
yaml --- r: 19063 b: refs/heads/autosynth-bigquerydatatransfer c: 9e56353 h: refs/heads/master i: 19061: 2f1eadc 19059: b15eda1 19055: 03e0194
1 parent da708f7 commit 3d72154

15 files changed

Lines changed: 5472 additions & 161 deletions

File tree

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ refs/tags/v0.68.0: 9cc799fcf68c82ab431d425fefa58ef615ce8e5b
123123
refs/tags/v0.69.0: 78f67a29e8b9c46ba01de566a2eae0fd1c03edea
124124
refs/heads/autosynth-asset: cd8251de8c40e239ad24dcf9ed93ea2708a3eed5
125125
refs/heads/autosynth-automl: 2a8b018cf05811fd472e5d1053e67a12ceec0b64
126-
refs/heads/autosynth-bigquerydatatransfer: 227f5b86f327f6b931c6b8ebe23f1f85c4da8862
126+
refs/heads/autosynth-bigquerydatatransfer: 9e5635377ced993530b410bb017f8efc64a91046
127127
refs/heads/autosynth-bigquerystorage: 14ab055598b943ae3f33f484e9fb1653355d08e7
128128
refs/heads/autosynth-bigtable: 2fbcb15847e0e89e79d6dc07420e28d7dfcea894
129129
refs/heads/autosynth-bigtable-admin: 6379a2bc712f2736c83de0e009b4d26da4fa82ca

branches/autosynth-bigquerydatatransfer/google-api-grpc/grpc-google-cloud-spanner-v1/src/main/java/com/google/spanner/v1/SpannerGrpc.java

Lines changed: 207 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -325,6 +325,61 @@ private SpannerGrpc() {}
325325
return getExecuteStreamingSqlMethod;
326326
}
327327

328+
@io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901")
329+
@java.lang.Deprecated // Use {@link #getExecuteBatchDmlMethod()} instead.
330+
public static final io.grpc.MethodDescriptor<
331+
com.google.spanner.v1.ExecuteBatchDmlRequest,
332+
com.google.spanner.v1.ExecuteBatchDmlResponse>
333+
METHOD_EXECUTE_BATCH_DML = getExecuteBatchDmlMethodHelper();
334+
335+
private static volatile io.grpc.MethodDescriptor<
336+
com.google.spanner.v1.ExecuteBatchDmlRequest,
337+
com.google.spanner.v1.ExecuteBatchDmlResponse>
338+
getExecuteBatchDmlMethod;
339+
340+
@io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901")
341+
public static io.grpc.MethodDescriptor<
342+
com.google.spanner.v1.ExecuteBatchDmlRequest,
343+
com.google.spanner.v1.ExecuteBatchDmlResponse>
344+
getExecuteBatchDmlMethod() {
345+
return getExecuteBatchDmlMethodHelper();
346+
}
347+
348+
private static io.grpc.MethodDescriptor<
349+
com.google.spanner.v1.ExecuteBatchDmlRequest,
350+
com.google.spanner.v1.ExecuteBatchDmlResponse>
351+
getExecuteBatchDmlMethodHelper() {
352+
io.grpc.MethodDescriptor<
353+
com.google.spanner.v1.ExecuteBatchDmlRequest,
354+
com.google.spanner.v1.ExecuteBatchDmlResponse>
355+
getExecuteBatchDmlMethod;
356+
if ((getExecuteBatchDmlMethod = SpannerGrpc.getExecuteBatchDmlMethod) == null) {
357+
synchronized (SpannerGrpc.class) {
358+
if ((getExecuteBatchDmlMethod = SpannerGrpc.getExecuteBatchDmlMethod) == null) {
359+
SpannerGrpc.getExecuteBatchDmlMethod =
360+
getExecuteBatchDmlMethod =
361+
io.grpc.MethodDescriptor
362+
.<com.google.spanner.v1.ExecuteBatchDmlRequest,
363+
com.google.spanner.v1.ExecuteBatchDmlResponse>
364+
newBuilder()
365+
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
366+
.setFullMethodName(
367+
generateFullMethodName("google.spanner.v1.Spanner", "ExecuteBatchDml"))
368+
.setSampledToLocalTracing(true)
369+
.setRequestMarshaller(
370+
io.grpc.protobuf.ProtoUtils.marshaller(
371+
com.google.spanner.v1.ExecuteBatchDmlRequest.getDefaultInstance()))
372+
.setResponseMarshaller(
373+
io.grpc.protobuf.ProtoUtils.marshaller(
374+
com.google.spanner.v1.ExecuteBatchDmlResponse.getDefaultInstance()))
375+
.setSchemaDescriptor(new SpannerMethodDescriptorSupplier("ExecuteBatchDml"))
376+
.build();
377+
}
378+
}
379+
}
380+
return getExecuteBatchDmlMethod;
381+
}
382+
328383
@io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901")
329384
@java.lang.Deprecated // Use {@link #getReadMethod()} instead.
330385
public static final io.grpc.MethodDescriptor<
@@ -757,7 +812,9 @@ public void listSessions(
757812
*
758813
*
759814
* <pre>
760-
* Ends a session, releasing server resources associated with it.
815+
* Ends a session, releasing server resources associated with it. This will
816+
* asynchronously trigger cancellation of any operations that are running with
817+
* this session.
761818
* </pre>
762819
*/
763820
public void deleteSession(
@@ -804,6 +861,35 @@ public void executeStreamingSql(
804861
asyncUnimplementedUnaryCall(getExecuteStreamingSqlMethodHelper(), responseObserver);
805862
}
806863

864+
/**
865+
*
866+
*
867+
* <pre>
868+
* Executes a batch of SQL DML statements. This method allows many statements
869+
* to be run with lower latency than submitting them sequentially with
870+
* [ExecuteSql][google.spanner.v1.Spanner.ExecuteSql].
871+
* Statements are executed in order, sequentially.
872+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse] will contain a
873+
* [ResultSet][google.spanner.v1.ResultSet] for each DML statement that has successfully executed. If a
874+
* statement fails, its error status will be returned as part of the
875+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse]. Execution will
876+
* stop at the first failed statement; the remaining statements will not run.
877+
* ExecuteBatchDml is expected to return an OK status with a response even if
878+
* there was an error while processing one of the DML statements. Clients must
879+
* inspect response.status to determine if there were any errors while
880+
* processing the request.
881+
* See more details in
882+
* [ExecuteBatchDmlRequest][Spanner.ExecuteBatchDmlRequest] and
883+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse].
884+
* </pre>
885+
*/
886+
public void executeBatchDml(
887+
com.google.spanner.v1.ExecuteBatchDmlRequest request,
888+
io.grpc.stub.StreamObserver<com.google.spanner.v1.ExecuteBatchDmlResponse>
889+
responseObserver) {
890+
asyncUnimplementedUnaryCall(getExecuteBatchDmlMethodHelper(), responseObserver);
891+
}
892+
807893
/**
808894
*
809895
*
@@ -984,6 +1070,13 @@ public final io.grpc.ServerServiceDefinition bindService() {
9841070
com.google.spanner.v1.ExecuteSqlRequest,
9851071
com.google.spanner.v1.PartialResultSet>(
9861072
this, METHODID_EXECUTE_STREAMING_SQL)))
1073+
.addMethod(
1074+
getExecuteBatchDmlMethodHelper(),
1075+
asyncUnaryCall(
1076+
new MethodHandlers<
1077+
com.google.spanner.v1.ExecuteBatchDmlRequest,
1078+
com.google.spanner.v1.ExecuteBatchDmlResponse>(
1079+
this, METHODID_EXECUTE_BATCH_DML)))
9871080
.addMethod(
9881081
getReadMethodHelper(),
9891082
asyncUnaryCall(
@@ -1122,7 +1215,9 @@ public void listSessions(
11221215
*
11231216
*
11241217
* <pre>
1125-
* Ends a session, releasing server resources associated with it.
1218+
* Ends a session, releasing server resources associated with it. This will
1219+
* asynchronously trigger cancellation of any operations that are running with
1220+
* this session.
11261221
* </pre>
11271222
*/
11281223
public void deleteSession(
@@ -1178,6 +1273,38 @@ public void executeStreamingSql(
11781273
responseObserver);
11791274
}
11801275

1276+
/**
1277+
*
1278+
*
1279+
* <pre>
1280+
* Executes a batch of SQL DML statements. This method allows many statements
1281+
* to be run with lower latency than submitting them sequentially with
1282+
* [ExecuteSql][google.spanner.v1.Spanner.ExecuteSql].
1283+
* Statements are executed in order, sequentially.
1284+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse] will contain a
1285+
* [ResultSet][google.spanner.v1.ResultSet] for each DML statement that has successfully executed. If a
1286+
* statement fails, its error status will be returned as part of the
1287+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse]. Execution will
1288+
* stop at the first failed statement; the remaining statements will not run.
1289+
* ExecuteBatchDml is expected to return an OK status with a response even if
1290+
* there was an error while processing one of the DML statements. Clients must
1291+
* inspect response.status to determine if there were any errors while
1292+
* processing the request.
1293+
* See more details in
1294+
* [ExecuteBatchDmlRequest][Spanner.ExecuteBatchDmlRequest] and
1295+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse].
1296+
* </pre>
1297+
*/
1298+
public void executeBatchDml(
1299+
com.google.spanner.v1.ExecuteBatchDmlRequest request,
1300+
io.grpc.stub.StreamObserver<com.google.spanner.v1.ExecuteBatchDmlResponse>
1301+
responseObserver) {
1302+
asyncUnaryCall(
1303+
getChannel().newCall(getExecuteBatchDmlMethodHelper(), getCallOptions()),
1304+
request,
1305+
responseObserver);
1306+
}
1307+
11811308
/**
11821309
*
11831310
*
@@ -1422,7 +1549,9 @@ public com.google.spanner.v1.ListSessionsResponse listSessions(
14221549
*
14231550
*
14241551
* <pre>
1425-
* Ends a session, releasing server resources associated with it.
1552+
* Ends a session, releasing server resources associated with it. This will
1553+
* asynchronously trigger cancellation of any operations that are running with
1554+
* this session.
14261555
* </pre>
14271556
*/
14281557
public com.google.protobuf.Empty deleteSession(
@@ -1469,6 +1598,34 @@ public java.util.Iterator<com.google.spanner.v1.PartialResultSet> executeStreami
14691598
getChannel(), getExecuteStreamingSqlMethodHelper(), getCallOptions(), request);
14701599
}
14711600

1601+
/**
1602+
*
1603+
*
1604+
* <pre>
1605+
* Executes a batch of SQL DML statements. This method allows many statements
1606+
* to be run with lower latency than submitting them sequentially with
1607+
* [ExecuteSql][google.spanner.v1.Spanner.ExecuteSql].
1608+
* Statements are executed in order, sequentially.
1609+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse] will contain a
1610+
* [ResultSet][google.spanner.v1.ResultSet] for each DML statement that has successfully executed. If a
1611+
* statement fails, its error status will be returned as part of the
1612+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse]. Execution will
1613+
* stop at the first failed statement; the remaining statements will not run.
1614+
* ExecuteBatchDml is expected to return an OK status with a response even if
1615+
* there was an error while processing one of the DML statements. Clients must
1616+
* inspect response.status to determine if there were any errors while
1617+
* processing the request.
1618+
* See more details in
1619+
* [ExecuteBatchDmlRequest][Spanner.ExecuteBatchDmlRequest] and
1620+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse].
1621+
* </pre>
1622+
*/
1623+
public com.google.spanner.v1.ExecuteBatchDmlResponse executeBatchDml(
1624+
com.google.spanner.v1.ExecuteBatchDmlRequest request) {
1625+
return blockingUnaryCall(
1626+
getChannel(), getExecuteBatchDmlMethodHelper(), getCallOptions(), request);
1627+
}
1628+
14721629
/**
14731630
*
14741631
*
@@ -1689,7 +1846,9 @@ protected SpannerFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions c
16891846
*
16901847
*
16911848
* <pre>
1692-
* Ends a session, releasing server resources associated with it.
1849+
* Ends a session, releasing server resources associated with it. This will
1850+
* asynchronously trigger cancellation of any operations that are running with
1851+
* this session.
16931852
* </pre>
16941853
*/
16951854
public com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Empty>
@@ -1719,6 +1878,35 @@ protected SpannerFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions c
17191878
getChannel().newCall(getExecuteSqlMethodHelper(), getCallOptions()), request);
17201879
}
17211880

1881+
/**
1882+
*
1883+
*
1884+
* <pre>
1885+
* Executes a batch of SQL DML statements. This method allows many statements
1886+
* to be run with lower latency than submitting them sequentially with
1887+
* [ExecuteSql][google.spanner.v1.Spanner.ExecuteSql].
1888+
* Statements are executed in order, sequentially.
1889+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse] will contain a
1890+
* [ResultSet][google.spanner.v1.ResultSet] for each DML statement that has successfully executed. If a
1891+
* statement fails, its error status will be returned as part of the
1892+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse]. Execution will
1893+
* stop at the first failed statement; the remaining statements will not run.
1894+
* ExecuteBatchDml is expected to return an OK status with a response even if
1895+
* there was an error while processing one of the DML statements. Clients must
1896+
* inspect response.status to determine if there were any errors while
1897+
* processing the request.
1898+
* See more details in
1899+
* [ExecuteBatchDmlRequest][Spanner.ExecuteBatchDmlRequest] and
1900+
* [ExecuteBatchDmlResponse][Spanner.ExecuteBatchDmlResponse].
1901+
* </pre>
1902+
*/
1903+
public com.google.common.util.concurrent.ListenableFuture<
1904+
com.google.spanner.v1.ExecuteBatchDmlResponse>
1905+
executeBatchDml(com.google.spanner.v1.ExecuteBatchDmlRequest request) {
1906+
return futureUnaryCall(
1907+
getChannel().newCall(getExecuteBatchDmlMethodHelper(), getCallOptions()), request);
1908+
}
1909+
17221910
/**
17231911
*
17241912
*
@@ -1851,13 +2039,14 @@ public com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Em
18512039
private static final int METHODID_DELETE_SESSION = 3;
18522040
private static final int METHODID_EXECUTE_SQL = 4;
18532041
private static final int METHODID_EXECUTE_STREAMING_SQL = 5;
1854-
private static final int METHODID_READ = 6;
1855-
private static final int METHODID_STREAMING_READ = 7;
1856-
private static final int METHODID_BEGIN_TRANSACTION = 8;
1857-
private static final int METHODID_COMMIT = 9;
1858-
private static final int METHODID_ROLLBACK = 10;
1859-
private static final int METHODID_PARTITION_QUERY = 11;
1860-
private static final int METHODID_PARTITION_READ = 12;
2042+
private static final int METHODID_EXECUTE_BATCH_DML = 6;
2043+
private static final int METHODID_READ = 7;
2044+
private static final int METHODID_STREAMING_READ = 8;
2045+
private static final int METHODID_BEGIN_TRANSACTION = 9;
2046+
private static final int METHODID_COMMIT = 10;
2047+
private static final int METHODID_ROLLBACK = 11;
2048+
private static final int METHODID_PARTITION_QUERY = 12;
2049+
private static final int METHODID_PARTITION_READ = 13;
18612050

18622051
private static final class MethodHandlers<Req, Resp>
18632052
implements io.grpc.stub.ServerCalls.UnaryMethod<Req, Resp>,
@@ -1908,6 +2097,12 @@ public void invoke(Req request, io.grpc.stub.StreamObserver<Resp> responseObserv
19082097
(io.grpc.stub.StreamObserver<com.google.spanner.v1.PartialResultSet>)
19092098
responseObserver);
19102099
break;
2100+
case METHODID_EXECUTE_BATCH_DML:
2101+
serviceImpl.executeBatchDml(
2102+
(com.google.spanner.v1.ExecuteBatchDmlRequest) request,
2103+
(io.grpc.stub.StreamObserver<com.google.spanner.v1.ExecuteBatchDmlResponse>)
2104+
responseObserver);
2105+
break;
19112106
case METHODID_READ:
19122107
serviceImpl.read(
19132108
(com.google.spanner.v1.ReadRequest) request,
@@ -2014,6 +2209,7 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() {
20142209
.addMethod(getDeleteSessionMethodHelper())
20152210
.addMethod(getExecuteSqlMethodHelper())
20162211
.addMethod(getExecuteStreamingSqlMethodHelper())
2212+
.addMethod(getExecuteBatchDmlMethodHelper())
20172213
.addMethod(getReadMethodHelper())
20182214
.addMethod(getStreamingReadMethodHelper())
20192215
.addMethod(getBeginTransactionMethodHelper())

0 commit comments

Comments
 (0)