Class: Google::Apis::ComputeV1::PerInstanceConfig

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
generated/google/apis/compute_v1/classes.rb,
generated/google/apis/compute_v1/representations.rb,
generated/google/apis/compute_v1/representations.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Google::Apis::Core::JsonObjectSupport

#to_json

Methods included from Google::Apis::Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ PerInstanceConfig

Returns a new instance of PerInstanceConfig.



19600
19601
19602
# File 'generated/google/apis/compute_v1/classes.rb', line 19600

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

Instance Attribute Details

#fingerprintString

Fingerprint of this per-instance config. This field may be used in optimistic locking. It will be ignored when inserting a per-instance config. An up-to- date fingerprint must be provided in order to update an existing per-instance config or the field needs to be unset. Corresponds to the JSON property fingerprint NOTE: Values are automatically base64 encoded/decoded in the client library.

Returns:

  • (String)


19588
19589
19590
# File 'generated/google/apis/compute_v1/classes.rb', line 19588

def fingerprint
  @fingerprint
end

#nameString

The name of the per-instance config and the corresponding instance. Serves as a merge key during UpdatePerInstanceConfigs operation, i.e. if per-instance config with the same name exists then it will be updated, otherwise a new one will be created for the VM instance with the same name. An attempt to create a per-instance config for a VM instance that either doesn't exist or is not part of the group will result in a failure. Corresponds to the JSON property name

Returns:

  • (String)


19598
19599
19600
# File 'generated/google/apis/compute_v1/classes.rb', line 19598

def name
  @name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



19605
19606
19607
19608
# File 'generated/google/apis/compute_v1/classes.rb', line 19605

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