public final class CommitRequest extends GeneratedMessageV3 implements CommitRequestOrBuilder
The request for [Commit][google.spanner.v1.Spanner.Commit].Protobuf type
google.spanner.v1.CommitRequest| Modifier and Type | Class and Description |
|---|---|
static class |
CommitRequest.Builder
The request for [Commit][google.spanner.v1.Spanner.Commit].
|
static class |
CommitRequest.TransactionCase |
GeneratedMessageV3.BuilderParent, GeneratedMessageV3.ExtendableBuilder<MessageType extends GeneratedMessageV3.ExtendableMessage,BuilderType extends GeneratedMessageV3.ExtendableBuilder<MessageType,BuilderType>>, GeneratedMessageV3.ExtendableMessage<MessageType extends GeneratedMessageV3.ExtendableMessage>, GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends GeneratedMessageV3.ExtendableMessage>, GeneratedMessageV3.FieldAccessorTable| Modifier and Type | Field and Description |
|---|---|
static int |
MUTATIONS_FIELD_NUMBER |
static int |
SESSION_FIELD_NUMBER |
static int |
SINGLE_USE_TRANSACTION_FIELD_NUMBER |
static int |
TRANSACTION_ID_FIELD_NUMBER |
alwaysUseFieldBuilders, unknownFieldsmemoizedSizememoizedHashCodecanUseUnsafe, computeStringSize, computeStringSizeNoTag, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneof, internalGetMapField, makeExtensionsImmutable, newBuilderForType, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringaddAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitfindInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneoftoByteArray, toByteString, writeDelimitedTo, writeTopublic static final int SESSION_FIELD_NUMBER
public static final int TRANSACTION_ID_FIELD_NUMBER
public static final int SINGLE_USE_TRANSACTION_FIELD_NUMBER
public static final int MUTATIONS_FIELD_NUMBER
public final UnknownFieldSet getUnknownFields()
getUnknownFields in interface MessageOrBuildergetUnknownFields in class GeneratedMessageV3public static final Descriptors.Descriptor getDescriptor()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class GeneratedMessageV3public CommitRequest.TransactionCase getTransactionCase()
getTransactionCase in interface CommitRequestOrBuilderpublic java.lang.String getSession()
Required. The session in which the transaction to be committed is running.
string session = 1;getSession in interface CommitRequestOrBuilderpublic ByteString getSessionBytes()
Required. The session in which the transaction to be committed is running.
string session = 1;getSessionBytes in interface CommitRequestOrBuilderpublic ByteString getTransactionId()
Commit a previously-started transaction.
bytes transaction_id = 2;getTransactionId in interface CommitRequestOrBuilderpublic boolean hasSingleUseTransaction()
Execute mutations in a temporary transaction. Note that unlike commit of a previously-started transaction, commit with a temporary transaction is non-idempotent. That is, if the `CommitRequest` is sent to Cloud Spanner more than once (for instance, due to retries in the application, or in the transport library), it is possible that the mutations are executed more than once. If this is undesirable, use [BeginTransaction][google.spanner.v1.Spanner.BeginTransaction] and [Commit][google.spanner.v1.Spanner.Commit] instead.
.google.spanner.v1.TransactionOptions single_use_transaction = 3;hasSingleUseTransaction in interface CommitRequestOrBuilderpublic TransactionOptions getSingleUseTransaction()
Execute mutations in a temporary transaction. Note that unlike commit of a previously-started transaction, commit with a temporary transaction is non-idempotent. That is, if the `CommitRequest` is sent to Cloud Spanner more than once (for instance, due to retries in the application, or in the transport library), it is possible that the mutations are executed more than once. If this is undesirable, use [BeginTransaction][google.spanner.v1.Spanner.BeginTransaction] and [Commit][google.spanner.v1.Spanner.Commit] instead.
.google.spanner.v1.TransactionOptions single_use_transaction = 3;getSingleUseTransaction in interface CommitRequestOrBuilderpublic TransactionOptionsOrBuilder getSingleUseTransactionOrBuilder()
Execute mutations in a temporary transaction. Note that unlike commit of a previously-started transaction, commit with a temporary transaction is non-idempotent. That is, if the `CommitRequest` is sent to Cloud Spanner more than once (for instance, due to retries in the application, or in the transport library), it is possible that the mutations are executed more than once. If this is undesirable, use [BeginTransaction][google.spanner.v1.Spanner.BeginTransaction] and [Commit][google.spanner.v1.Spanner.Commit] instead.
.google.spanner.v1.TransactionOptions single_use_transaction = 3;getSingleUseTransactionOrBuilder in interface CommitRequestOrBuilderpublic java.util.List<Mutation> getMutationsList()
The mutations to be executed when this transaction commits. All mutations are applied atomically, in the order they appear in this list.
repeated .google.spanner.v1.Mutation mutations = 4;getMutationsList in interface CommitRequestOrBuilderpublic java.util.List<? extends MutationOrBuilder> getMutationsOrBuilderList()
The mutations to be executed when this transaction commits. All mutations are applied atomically, in the order they appear in this list.
repeated .google.spanner.v1.Mutation mutations = 4;getMutationsOrBuilderList in interface CommitRequestOrBuilderpublic int getMutationsCount()
The mutations to be executed when this transaction commits. All mutations are applied atomically, in the order they appear in this list.
repeated .google.spanner.v1.Mutation mutations = 4;getMutationsCount in interface CommitRequestOrBuilderpublic Mutation getMutations(int index)
The mutations to be executed when this transaction commits. All mutations are applied atomically, in the order they appear in this list.
repeated .google.spanner.v1.Mutation mutations = 4;getMutations in interface CommitRequestOrBuilderpublic MutationOrBuilder getMutationsOrBuilder(int index)
The mutations to be executed when this transaction commits. All mutations are applied atomically, in the order they appear in this list.
repeated .google.spanner.v1.Mutation mutations = 4;getMutationsOrBuilder in interface CommitRequestOrBuilderpublic final boolean isInitialized()
isInitialized in interface MessageLiteOrBuilderisInitialized in class GeneratedMessageV3public void writeTo(CodedOutputStream output) throws java.io.IOException
writeTo in interface MessageLitewriteTo in class GeneratedMessageV3java.io.IOExceptionpublic int getSerializedSize()
getSerializedSize in interface MessageLitegetSerializedSize in class GeneratedMessageV3public boolean equals(java.lang.Object obj)
equals in interface Messageequals in class AbstractMessagepublic int hashCode()
hashCode in interface MessagehashCode in class AbstractMessagepublic static CommitRequest parseFrom(java.nio.ByteBuffer data) throws InvalidProtocolBufferException
InvalidProtocolBufferExceptionpublic static CommitRequest parseFrom(java.nio.ByteBuffer data, ExtensionRegistryLite extensionRegistry) throws InvalidProtocolBufferException
InvalidProtocolBufferExceptionpublic static CommitRequest parseFrom(ByteString data) throws InvalidProtocolBufferException
InvalidProtocolBufferExceptionpublic static CommitRequest parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry) throws InvalidProtocolBufferException
InvalidProtocolBufferExceptionpublic static CommitRequest parseFrom(byte[] data) throws InvalidProtocolBufferException
InvalidProtocolBufferExceptionpublic static CommitRequest parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry) throws InvalidProtocolBufferException
InvalidProtocolBufferExceptionpublic static CommitRequest parseFrom(java.io.InputStream input) throws java.io.IOException
java.io.IOExceptionpublic static CommitRequest parseFrom(java.io.InputStream input, ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOExceptionpublic static CommitRequest parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException
java.io.IOExceptionpublic static CommitRequest parseDelimitedFrom(java.io.InputStream input, ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOExceptionpublic static CommitRequest parseFrom(CodedInputStream input) throws java.io.IOException
java.io.IOExceptionpublic static CommitRequest parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOExceptionpublic CommitRequest.Builder newBuilderForType()
newBuilderForType in interface MessagenewBuilderForType in interface MessageLitepublic static CommitRequest.Builder newBuilder()
public static CommitRequest.Builder newBuilder(CommitRequest prototype)
public CommitRequest.Builder toBuilder()
toBuilder in interface MessagetoBuilder in interface MessageLiteprotected CommitRequest.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class GeneratedMessageV3public static CommitRequest getDefaultInstance()
public static Parser<CommitRequest> parser()
public Parser<CommitRequest> getParserForType()
getParserForType in interface MessagegetParserForType in interface MessageLitegetParserForType in class GeneratedMessageV3public CommitRequest getDefaultInstanceForType()
getDefaultInstanceForType in interface MessageLiteOrBuildergetDefaultInstanceForType in interface MessageOrBuilder