Class: Google::Apis::ComputeAlpha::PerInstanceConfig

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
generated/google/apis/compute_alpha/classes.rb,
generated/google/apis/compute_alpha/representations.rb,
generated/google/apis/compute_alpha/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



20518
20519
20520
# File 'generated/google/apis/compute_alpha/classes.rb', line 20518

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)


20489
20490
20491
# File 'generated/google/apis/compute_alpha/classes.rb', line 20489

def fingerprint
  @fingerprint
end

#instanceString

The URL of the instance. Serves as a merge key during UpdatePerInstanceConfigs operation, i.e. if per-instance config with the same instance URL exists then it will be updated, otherwise a new one will be created. Corresponds to the JSON property instance

Returns:

  • (String)


20496
20497
20498
# File 'generated/google/apis/compute_alpha/classes.rb', line 20496

def instance
  @instance
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)


20506
20507
20508
# File 'generated/google/apis/compute_alpha/classes.rb', line 20506

def name
  @name
end

#overrideGoogle::Apis::ComputeAlpha::ManagedInstanceOverride

Overrides of stateful properties for a given instance Corresponds to the JSON property override



20511
20512
20513
# File 'generated/google/apis/compute_alpha/classes.rb', line 20511

def override
  @override
end

#preserved_stateGoogle::Apis::ComputeAlpha::PreservedState

Preserved state for a given instance. Corresponds to the JSON property preservedState



20516
20517
20518
# File 'generated/google/apis/compute_alpha/classes.rb', line 20516

def preserved_state
  @preserved_state
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



20523
20524
20525
20526
20527
20528
20529
# File 'generated/google/apis/compute_alpha/classes.rb', line 20523

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