Google Cloud Spanner v1 API - Class DirectedReadOptions.Types.ReplicaSelection (5.0.0-beta02)

public sealed class DirectedReadOptions.Types.ReplicaSelection : IMessage<DirectedReadOptions.Types.ReplicaSelection>, IEquatable<DirectedReadOptions.Types.ReplicaSelection>, IDeepCloneable<DirectedReadOptions.Types.ReplicaSelection>, IBufferMessage, IMessage

Reference documentation and code samples for the Google Cloud Spanner v1 API class DirectedReadOptions.Types.ReplicaSelection.

The directed read replica selector. Callers must provide one or more of the following fields for replica selection:

  • location - The location must be one of the regions within the multi-region configuration of your database.
  • type - The type of the replica.

Some examples of using replica_selectors are:

  • location:us-east1 --> The "us-east1" replica(s) of any available type will be used to process the request.
  • type:READ_ONLY --> The "READ_ONLY" type replica(s) in nearest available location will be used to process the request.
  • location:us-east1 type:READ_ONLY --> The "READ_ONLY" type replica(s) in location "us-east1" will be used to process the request.

Inheritance

object > DirectedReadOptions.Types.ReplicaSelection

Namespace

Google.Cloud.Spanner.V1

Assembly

Google.Cloud.Spanner.V1.dll

Constructors

ReplicaSelection()

public ReplicaSelection()

ReplicaSelection(ReplicaSelection)

public ReplicaSelection(DirectedReadOptions.Types.ReplicaSelection other)
Parameter
NameDescription
otherDirectedReadOptionsTypesReplicaSelection

Properties

Location

public string Location { get; set; }

The location or region of the serving requests, e.g. "us-east1".

Property Value
TypeDescription
string

Type

public DirectedReadOptions.Types.ReplicaSelection.Types.Type Type { get; set; }

The type of replica.

Property Value
TypeDescription
DirectedReadOptionsTypesReplicaSelectionTypesType