Skip to content

feat: Update TransactionOptions to include new option exclude_txn_from_change_streams #2853

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 13 commits into from
Feb 17, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Prev Previous commit
Next Next commit
🦉 Updates from OwlBot post-processor
  • Loading branch information
gcf-owl-bot[bot] committed Feb 14, 2024
commit 77b7bd445406faa94321fa6cf03b1db339d053f1
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@
import com.google.api.gax.rpc.ClientSettings;
import com.google.api.gax.rpc.OperationCallSettings;
import com.google.api.gax.rpc.PagedCallSettings;
import com.google.api.gax.rpc.StubSettings;
import com.google.api.gax.rpc.TransportChannelProvider;
import com.google.api.gax.rpc.UnaryCallSettings;
import com.google.cloud.spanner.admin.database.v1.stub.DatabaseAdminStubSettings;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@
import io.grpc.MethodDescriptor;
import io.grpc.protobuf.ProtoUtils;
import java.io.IOException;
import java.util.Map;
import java.util.concurrent.TimeUnit;
import javax.annotation.Generated;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@
import com.google.api.gax.httpjson.ProtoMessageResponseParser;
import com.google.api.gax.httpjson.ProtoRestSerializer;
import com.google.api.gax.httpjson.longrunning.stub.HttpJsonOperationsStub;
import com.google.api.gax.longrunning.OperationSnapshot;
import com.google.api.gax.rpc.ClientContext;
import com.google.api.gax.rpc.OperationCallable;
import com.google.api.gax.rpc.RequestParamsBuilder;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
import com.google.api.gax.rpc.ClientSettings;
import com.google.api.gax.rpc.OperationCallSettings;
import com.google.api.gax.rpc.PagedCallSettings;
import com.google.api.gax.rpc.StubSettings;
import com.google.api.gax.rpc.TransportChannelProvider;
import com.google.api.gax.rpc.UnaryCallSettings;
import com.google.cloud.spanner.admin.instance.v1.stub.InstanceAdminStubSettings;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@
import io.grpc.MethodDescriptor;
import io.grpc.protobuf.ProtoUtils;
import java.io.IOException;
import java.util.Map;
import java.util.concurrent.TimeUnit;
import javax.annotation.Generated;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@
import com.google.api.gax.httpjson.ProtoMessageResponseParser;
import com.google.api.gax.httpjson.ProtoRestSerializer;
import com.google.api.gax.httpjson.longrunning.stub.HttpJsonOperationsStub;
import com.google.api.gax.longrunning.OperationSnapshot;
import com.google.api.gax.rpc.ClientContext;
import com.google.api.gax.rpc.OperationCallable;
import com.google.api.gax.rpc.RequestParamsBuilder;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
import com.google.api.gax.rpc.ClientSettings;
import com.google.api.gax.rpc.PagedCallSettings;
import com.google.api.gax.rpc.ServerStreamingCallSettings;
import com.google.api.gax.rpc.StubSettings;
import com.google.api.gax.rpc.TransportChannelProvider;
import com.google.api.gax.rpc.UnaryCallSettings;
import com.google.cloud.spanner.v1.stub.SpannerStubSettings;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@
import io.grpc.MethodDescriptor;
import io.grpc.protobuf.ProtoUtils;
import java.io.IOException;
import java.util.Map;
import java.util.concurrent.TimeUnit;
import javax.annotation.Generated;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ public void createSessionTest() throws Exception {
.setCreateTime(Timestamp.newBuilder().build())
.setApproximateLastUseTime(Timestamp.newBuilder().build())
.setCreatorRole("creatorRole-190742846")
.setMultiplexed(true)
.build();
mockService.addResponse(expectedResponse);

Expand Down Expand Up @@ -167,6 +168,7 @@ public void createSessionTest2() throws Exception {
.setCreateTime(Timestamp.newBuilder().build())
.setApproximateLastUseTime(Timestamp.newBuilder().build())
.setCreatorRole("creatorRole-190742846")
.setMultiplexed(true)
.build();
mockService.addResponse(expectedResponse);

Expand Down Expand Up @@ -304,6 +306,7 @@ public void getSessionTest() throws Exception {
.setCreateTime(Timestamp.newBuilder().build())
.setApproximateLastUseTime(Timestamp.newBuilder().build())
.setCreatorRole("creatorRole-190742846")
.setMultiplexed(true)
.build();
mockService.addResponse(expectedResponse);

Expand Down Expand Up @@ -353,6 +356,7 @@ public void getSessionTest2() throws Exception {
.setCreateTime(Timestamp.newBuilder().build())
.setApproximateLastUseTime(Timestamp.newBuilder().build())
.setCreatorRole("creatorRole-190742846")
.setMultiplexed(true)
.build();
mockService.addResponse(expectedResponse);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ public void createSessionTest() throws Exception {
.setCreateTime(Timestamp.newBuilder().build())
.setApproximateLastUseTime(Timestamp.newBuilder().build())
.setCreatorRole("creatorRole-190742846")
.setMultiplexed(true)
.build();
mockSpanner.addResponse(expectedResponse);

Expand Down Expand Up @@ -181,6 +182,7 @@ public void createSessionTest2() throws Exception {
.setCreateTime(Timestamp.newBuilder().build())
.setApproximateLastUseTime(Timestamp.newBuilder().build())
.setCreatorRole("creatorRole-190742846")
.setMultiplexed(true)
.build();
mockSpanner.addResponse(expectedResponse);

Expand Down Expand Up @@ -302,6 +304,7 @@ public void getSessionTest() throws Exception {
.setCreateTime(Timestamp.newBuilder().build())
.setApproximateLastUseTime(Timestamp.newBuilder().build())
.setCreatorRole("creatorRole-190742846")
.setMultiplexed(true)
.build();
mockSpanner.addResponse(expectedResponse);

Expand Down Expand Up @@ -345,6 +348,7 @@ public void getSessionTest2() throws Exception {
.setCreateTime(Timestamp.newBuilder().build())
.setApproximateLastUseTime(Timestamp.newBuilder().build())
.setCreatorRole("creatorRole-190742846")
.setMultiplexed(true)
.build();
mockSpanner.addResponse(expectedResponse);

Expand Down Expand Up @@ -1388,6 +1392,7 @@ public void batchWriteTest() throws Exception {
SessionName.of("[PROJECT]", "[INSTANCE]", "[DATABASE]", "[SESSION]").toString())
.setRequestOptions(RequestOptions.newBuilder().build())
.addAllMutationGroups(new ArrayList<BatchWriteRequest.MutationGroup>())
.setExcludeTxnFromChangeStreams(true)
.build();

MockStreamObserver<BatchWriteResponse> responseObserver = new MockStreamObserver<>();
Expand All @@ -1411,6 +1416,7 @@ public void batchWriteExceptionTest() throws Exception {
SessionName.of("[PROJECT]", "[INSTANCE]", "[DATABASE]", "[SESSION]").toString())
.setRequestOptions(RequestOptions.newBuilder().build())
.addAllMutationGroups(new ArrayList<BatchWriteRequest.MutationGroup>())
.setExcludeTxnFromChangeStreams(true)
.build();

MockStreamObserver<BatchWriteResponse> responseObserver = new MockStreamObserver<>();
Expand Down
Loading