Google Cloud Spanner v1 API - Class CommitRequest (4.2.0)

public sealed class CommitRequest : IMessage<CommitRequest>, IEquatable<CommitRequest>, IDeepCloneable<CommitRequest>, IBufferMessage, IMessage

Reference documentation and code samples for the Google Cloud Spanner v1 API class CommitRequest.

The request for [Commit][google.spanner.v1.Spanner.Commit].

Inheritance

Object > CommitRequest

Namespace

Google.Cloud.Spanner.V1

Assembly

Google.Cloud.Spanner.V1.dll

Constructors

CommitRequest()

public CommitRequest()

CommitRequest(CommitRequest)

public CommitRequest(CommitRequest other)
Parameter
NameDescription
otherCommitRequest

Properties

Mutations

public RepeatedField<Mutation> Mutations { get; }

The mutations to be executed when this transaction commits. All mutations are applied atomically, in the order they appear in this list.

Property Value
TypeDescription
RepeatedField<Mutation>

RequestOptions

public RequestOptions RequestOptions { get; set; }

Common options for this request.

Property Value
TypeDescription
RequestOptions

ReturnCommitStats

public bool ReturnCommitStats { get; set; }

If true, then statistics related to the transaction will be included in the [CommitResponse][google.spanner.v1.CommitResponse.commit_stats]. Default value is false.

Property Value
TypeDescription
Boolean

Session

public string Session { get; set; }

Required. The session in which the transaction to be committed is running.

Property Value
TypeDescription
String

SessionAsSessionName

public SessionName SessionAsSessionName { get; set; }

SessionName-typed view over the Session resource name property.

Property Value
TypeDescription
SessionName

SingleUseTransaction

public TransactionOptions SingleUseTransaction { get; set; }

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.

Property Value
TypeDescription
TransactionOptions

TransactionCase

public CommitRequest.TransactionOneofCase TransactionCase { get; }
Property Value
TypeDescription
CommitRequest.TransactionOneofCase

TransactionId

public ByteString TransactionId { get; set; }

Commit a previously-started transaction.

Property Value
TypeDescription
ByteString