Class: Google::Apis::SpannerV1::ReplicaComputeCapacity

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/spanner_v1/classes.rb,
lib/google/apis/spanner_v1/representations.rb,
lib/google/apis/spanner_v1/representations.rb

Overview

ReplicaComputeCapacity describes the amount of server resources that are allocated to each replica identified by the replica selection.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ReplicaComputeCapacity

Returns a new instance of ReplicaComputeCapacity.



5869
5870
5871
# File 'lib/google/apis/spanner_v1/classes.rb', line 5869

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#node_countFixnum

The number of nodes allocated to each replica. This may be zero in API responses for instances that are not yet in state READY. Corresponds to the JSON property nodeCount

Returns:

  • (Fixnum)


5856
5857
5858
# File 'lib/google/apis/spanner_v1/classes.rb', line 5856

def node_count
  @node_count
end

#processing_unitsFixnum

The number of processing units allocated to each replica. This may be zero in API responses for instances that are not yet in state READY. Corresponds to the JSON property processingUnits

Returns:

  • (Fixnum)


5862
5863
5864
# File 'lib/google/apis/spanner_v1/classes.rb', line 5862

def processing_units
  @processing_units
end

#replica_selectionGoogle::Apis::SpannerV1::InstanceReplicaSelection

ReplicaSelection identifies replicas with common properties. Corresponds to the JSON property replicaSelection



5867
5868
5869
# File 'lib/google/apis/spanner_v1/classes.rb', line 5867

def replica_selection
  @replica_selection
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



5874
5875
5876
5877
5878
# File 'lib/google/apis/spanner_v1/classes.rb', line 5874

def update!(**args)
  @node_count = args[:node_count] if args.key?(:node_count)
  @processing_units = args[:processing_units] if args.key?(:processing_units)
  @replica_selection = args[:replica_selection] if args.key?(:replica_selection)
end