Class: Google::Apis::ComputeAlpha::NodeGroup

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

Overview

Represent a sole-tenant Node Group resource. A sole-tenant node is a physical server that is dedicated to hosting VM instances only for your specific project. Use sole-tenant nodes to keep your instances physically separated from instances in other projects, or to group your instances together on the same host hardware. For more information, read Sole-tenant nodes. (== resource_for $api_version.nodeGroups ==)

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ NodeGroup

Returns a new instance of NodeGroup.



23433
23434
23435
# File 'lib/google/apis/compute_alpha/classes.rb', line 23433

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

Instance Attribute Details

#autoscaling_policyGoogle::Apis::ComputeAlpha::NodeGroupAutoscalingPolicy

Specifies how autoscaling should behave. Corresponds to the JSON property autoscalingPolicy



23339
23340
23341
# File 'lib/google/apis/compute_alpha/classes.rb', line 23339

def autoscaling_policy
  @autoscaling_policy
end

#creation_timestampString

[Output Only] Creation timestamp in RFC3339 text format. Corresponds to the JSON property creationTimestamp

Returns:

  • (String)


23344
23345
23346
# File 'lib/google/apis/compute_alpha/classes.rb', line 23344

def creation_timestamp
  @creation_timestamp
end

#descriptionString

An optional description of this resource. Provide this property when you create the resource. Corresponds to the JSON property description

Returns:

  • (String)


23350
23351
23352
# File 'lib/google/apis/compute_alpha/classes.rb', line 23350

def description
  @description
end

#fingerprintString

Corresponds to the JSON property fingerprint NOTE: Values are automatically base64 encoded/decoded in the client library.

Returns:

  • (String)


23356
23357
23358
# File 'lib/google/apis/compute_alpha/classes.rb', line 23356

def fingerprint
  @fingerprint
end

#idFixnum

[Output Only] The unique identifier for the resource. This identifier is defined by the server. Corresponds to the JSON property id

Returns:

  • (Fixnum)


23362
23363
23364
# File 'lib/google/apis/compute_alpha/classes.rb', line 23362

def id
  @id
end

#kindString

[Output Only] The type of the resource. Always compute#nodeGroup for node group. Corresponds to the JSON property kind

Returns:

  • (String)


23368
23369
23370
# File 'lib/google/apis/compute_alpha/classes.rb', line 23368

def kind
  @kind
end

#location_hintString

An opaque location hint used to place the Node close to other resources. This field is for use by internal tools that use the public API. The location hint here on the NodeGroup overrides any location_hint present in the NodeTemplate. Corresponds to the JSON property locationHint

Returns:

  • (String)


23375
23376
23377
# File 'lib/google/apis/compute_alpha/classes.rb', line 23375

def location_hint
  @location_hint
end

#maintenance_policyString

Specifies how to handle instances when a node in the group undergoes maintenance. Set to one of: DEFAULT, RESTART_IN_PLACE, or MIGRATE_WITHIN_NODE_GROUP. The default value is DEFAULT. For more information, see Maintenance policies. Corresponds to the JSON property maintenancePolicy

Returns:

  • (String)


23383
23384
23385
# File 'lib/google/apis/compute_alpha/classes.rb', line 23383

def maintenance_policy
  @maintenance_policy
end

#maintenance_windowGoogle::Apis::ComputeAlpha::NodeGroupMaintenanceWindow

Time window specified for daily maintenance operations. GCE's internal maintenance will be performed within this window. Corresponds to the JSON property maintenanceWindow



23389
23390
23391
# File 'lib/google/apis/compute_alpha/classes.rb', line 23389

def maintenance_window
  @maintenance_window
end

#nameString

The name of the resource, provided by the client when initially creating the resource. The resource name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. Corresponds to the JSON property name

Returns:

  • (String)


23400
23401
23402
# File 'lib/google/apis/compute_alpha/classes.rb', line 23400

def name
  @name
end

#node_templateString

URL of the node template to create the node group from. Corresponds to the JSON property nodeTemplate

Returns:

  • (String)


23405
23406
23407
# File 'lib/google/apis/compute_alpha/classes.rb', line 23405

def node_template
  @node_template
end

[Output Only] Server-defined URL for the resource. Corresponds to the JSON property selfLink

Returns:

  • (String)


23410
23411
23412
# File 'lib/google/apis/compute_alpha/classes.rb', line 23410

def self_link
  @self_link
end

[Output Only] Server-defined URL for this resource with the resource id. Corresponds to the JSON property selfLinkWithId

Returns:

  • (String)


23415
23416
23417
# File 'lib/google/apis/compute_alpha/classes.rb', line 23415

def self_link_with_id
  @self_link_with_id
end

#sizeFixnum

[Output Only] The total number of nodes in the node group. Corresponds to the JSON property size

Returns:

  • (Fixnum)


23420
23421
23422
# File 'lib/google/apis/compute_alpha/classes.rb', line 23420

def size
  @size
end

#statusString

Corresponds to the JSON property status

Returns:

  • (String)


23425
23426
23427
# File 'lib/google/apis/compute_alpha/classes.rb', line 23425

def status
  @status
end

#zoneString

[Output Only] The name of the zone where the node group resides, such as us- central1-a. Corresponds to the JSON property zone

Returns:

  • (String)


23431
23432
23433
# File 'lib/google/apis/compute_alpha/classes.rb', line 23431

def zone
  @zone
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



23438
23439
23440
23441
23442
23443
23444
23445
23446
23447
23448
23449
23450
23451
23452
23453
23454
23455
# File 'lib/google/apis/compute_alpha/classes.rb', line 23438

def update!(**args)
  @autoscaling_policy = args[:autoscaling_policy] if args.key?(:autoscaling_policy)
  @creation_timestamp = args[:creation_timestamp] if args.key?(:creation_timestamp)
  @description = args[:description] if args.key?(:description)
  @fingerprint = args[:fingerprint] if args.key?(:fingerprint)
  @id = args[:id] if args.key?(:id)
  @kind = args[:kind] if args.key?(:kind)
  @location_hint = args[:location_hint] if args.key?(:location_hint)
  @maintenance_policy = args[:maintenance_policy] if args.key?(:maintenance_policy)
  @maintenance_window = args[:maintenance_window] if args.key?(:maintenance_window)
  @name = args[:name] if args.key?(:name)
  @node_template = args[:node_template] if args.key?(:node_template)
  @self_link = args[:self_link] if args.key?(:self_link)
  @self_link_with_id = args[:self_link_with_id] if args.key?(:self_link_with_id)
  @size = args[:size] if args.key?(:size)
  @status = args[:status] if args.key?(:status)
  @zone = args[:zone] if args.key?(:zone)
end