Class: Google::Apis::SpannerV1::AutoscalingLimits
- Inherits:
-
Object
- Object
- Google::Apis::SpannerV1::AutoscalingLimits
- 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
The autoscaling limits for the instance. Users can define the minimum and maximum compute capacity allocated to the instance, and the autoscaler will only scale within that range. Users can either use nodes or processing units to specify the limits, but should use the same unit to set both the min_limit and max_limit.
Instance Attribute Summary collapse
-
#max_nodes ⇒ Fixnum
Maximum number of nodes allocated to the instance.
-
#max_processing_units ⇒ Fixnum
Maximum number of processing units allocated to the instance.
-
#min_nodes ⇒ Fixnum
Minimum number of nodes allocated to the instance.
-
#min_processing_units ⇒ Fixnum
Minimum number of processing units allocated to the instance.
Instance Method Summary collapse
-
#initialize(**args) ⇒ AutoscalingLimits
constructor
A new instance of AutoscalingLimits.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ AutoscalingLimits
Returns a new instance of AutoscalingLimits.
289 290 291 |
# File 'lib/google/apis/spanner_v1/classes.rb', line 289 def initialize(**args) update!(**args) end |
Instance Attribute Details
#max_nodes ⇒ Fixnum
Maximum number of nodes allocated to the instance. If set, this number should
be greater than or equal to min_nodes.
Corresponds to the JSON property maxNodes
268 269 270 |
# File 'lib/google/apis/spanner_v1/classes.rb', line 268 def max_nodes @max_nodes end |
#max_processing_units ⇒ Fixnum
Maximum number of processing units allocated to the instance. If set, this
number should be multiples of 1000 and be greater than or equal to
min_processing_units.
Corresponds to the JSON property maxProcessingUnits
275 276 277 |
# File 'lib/google/apis/spanner_v1/classes.rb', line 275 def max_processing_units @max_processing_units end |
#min_nodes ⇒ Fixnum
Minimum number of nodes allocated to the instance. If set, this number should
be greater than or equal to 1.
Corresponds to the JSON property minNodes
281 282 283 |
# File 'lib/google/apis/spanner_v1/classes.rb', line 281 def min_nodes @min_nodes end |
#min_processing_units ⇒ Fixnum
Minimum number of processing units allocated to the instance. If set, this
number should be multiples of 1000.
Corresponds to the JSON property minProcessingUnits
287 288 289 |
# File 'lib/google/apis/spanner_v1/classes.rb', line 287 def min_processing_units @min_processing_units end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
294 295 296 297 298 299 |
# File 'lib/google/apis/spanner_v1/classes.rb', line 294 def update!(**args) @max_nodes = args[:max_nodes] if args.key?(:max_nodes) @max_processing_units = args[:max_processing_units] if args.key?(:max_processing_units) @min_nodes = args[:min_nodes] if args.key?(:min_nodes) @min_processing_units = args[:min_processing_units] if args.key?(:min_processing_units) end |