Class: Google::Apis::RunV1::WorkerPoolSpec

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

Overview

WorkerPoolSpec holds the desired state of the WorkerPool's template and instance splits.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ WorkerPoolSpec

Returns a new instance of WorkerPoolSpec.



6862
6863
6864
# File 'lib/google/apis/run_v1/classes.rb', line 6862

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

Instance Attribute Details

#instance_splitsArray<Google::Apis::RunV1::InstanceSplit>

Specifies how to distribute instances over a collection of Revisions. Corresponds to the JSON property instanceSplits



6854
6855
6856
# File 'lib/google/apis/run_v1/classes.rb', line 6854

def instance_splits
  @instance_splits
end

#templateGoogle::Apis::RunV1::RevisionTemplate

RevisionTemplateSpec describes the data a revision should have when created from a template. Corresponds to the JSON property template



6860
6861
6862
# File 'lib/google/apis/run_v1/classes.rb', line 6860

def template
  @template
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



6867
6868
6869
6870
# File 'lib/google/apis/run_v1/classes.rb', line 6867

def update!(**args)
  @instance_splits = args[:instance_splits] if args.key?(:instance_splits)
  @template = args[:template] if args.key?(:template)
end