Class: Google::Apis::TpuV2alpha1::Node

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

Overview

A TPU instance.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Node

Returns a new instance of Node.



999
1000
1001
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 999

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

Instance Attribute Details

#accelerator_configGoogle::Apis::TpuV2alpha1::AcceleratorConfig

A TPU accelerator configuration. Corresponds to the JSON property acceleratorConfig



859
860
861
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 859

def accelerator_config
  @accelerator_config
end

#accelerator_typeString

The type of hardware accelerators associated with this node. Corresponds to the JSON property acceleratorType

Returns:

  • (String)


864
865
866
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 864

def accelerator_type
  @accelerator_type
end

#api_versionString

Output only. The API version that created this Node. Corresponds to the JSON property apiVersion

Returns:

  • (String)


869
870
871
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 869

def api_version
  @api_version
end

#autocheckpoint_enabledBoolean Also known as: autocheckpoint_enabled?

Optional. Whether Autocheckpoint is enabled. Corresponds to the JSON property autocheckpointEnabled

Returns:

  • (Boolean)


874
875
876
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 874

def autocheckpoint_enabled
  @autocheckpoint_enabled
end

#boot_disk_configGoogle::Apis::TpuV2alpha1::BootDiskConfig

Boot disk configurations. Corresponds to the JSON property bootDiskConfig



880
881
882
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 880

def boot_disk_config
  @boot_disk_config
end

#cidr_blockString

The CIDR block that the TPU node will use when selecting an IP address. This CIDR block must be a /29 block; the Compute Engine networks API forbids a smaller block, and using a larger block would be wasteful (a node can only consume one IP address). Errors will occur if the CIDR block has already been used for a currently existing TPU node, the CIDR block conflicts with any subnetworks in the user's provided network, or the provided network is peered with another network that is using that CIDR block. Corresponds to the JSON property cidrBlock

Returns:

  • (String)


891
892
893
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 891

def cidr_block
  @cidr_block
end

#create_timeString

Output only. The time when the node was created. Corresponds to the JSON property createTime

Returns:

  • (String)


896
897
898
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 896

def create_time
  @create_time
end

#data_disksArray<Google::Apis::TpuV2alpha1::AttachedDisk>

The additional data disks for the Node. Corresponds to the JSON property dataDisks



901
902
903
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 901

def data_disks
  @data_disks
end

#descriptionString

The user-supplied description of the TPU. Maximum of 512 characters. Corresponds to the JSON property description

Returns:

  • (String)


906
907
908
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 906

def description
  @description
end

#healthString

The health status of the TPU node. Corresponds to the JSON property health

Returns:

  • (String)


911
912
913
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 911

def health
  @health
end

#health_descriptionString

Output only. If this field is populated, it contains a description of why the TPU Node is unhealthy. Corresponds to the JSON property healthDescription

Returns:

  • (String)


917
918
919
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 917

def health_description
  @health_description
end

#idFixnum

Output only. The unique identifier for the TPU Node. Corresponds to the JSON property id

Returns:

  • (Fixnum)


922
923
924
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 922

def id
  @id
end

#labelsHash<String,String>

Resource labels to represent user-provided metadata. Corresponds to the JSON property labels

Returns:

  • (Hash<String,String>)


927
928
929
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 927

def labels
  @labels
end

#metadataHash<String,String>

Custom metadata to apply to the TPU Node. Can set startup-script and shutdown- script Corresponds to the JSON property metadata

Returns:

  • (Hash<String,String>)


933
934
935
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 933

def 
  @metadata
end

#multislice_nodeBoolean Also known as: multislice_node?

Output only. Whether the Node belongs to a Multislice group. Corresponds to the JSON property multisliceNode

Returns:

  • (Boolean)


938
939
940
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 938

def multislice_node
  @multislice_node
end

#nameString

Output only. Immutable. The name of the TPU. Corresponds to the JSON property name

Returns:

  • (String)


944
945
946
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 944

def name
  @name
end

#network_configGoogle::Apis::TpuV2alpha1::NetworkConfig

Network related configurations. Corresponds to the JSON property networkConfig



949
950
951
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 949

def network_config
  @network_config
end

#network_endpointsArray<Google::Apis::TpuV2alpha1::NetworkEndpoint>

Output only. The network endpoints where TPU workers can be accessed and sent work. It is recommended that runtime clients of the node reach out to the 0th entry in this map first. Corresponds to the JSON property networkEndpoints



956
957
958
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 956

def network_endpoints
  @network_endpoints
end

#queued_resourceString

Output only. The qualified name of the QueuedResource that requested this Node. Corresponds to the JSON property queuedResource

Returns:

  • (String)


961
962
963
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 961

def queued_resource
  @queued_resource
end

#runtime_versionString

Required. The runtime version running in the Node. Corresponds to the JSON property runtimeVersion

Returns:

  • (String)


966
967
968
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 966

def runtime_version
  @runtime_version
end

#scheduling_configGoogle::Apis::TpuV2alpha1::SchedulingConfig

Sets the scheduling options for this node. Corresponds to the JSON property schedulingConfig



971
972
973
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 971

def scheduling_config
  @scheduling_config
end

#service_accountGoogle::Apis::TpuV2alpha1::ServiceAccount

A service account. Corresponds to the JSON property serviceAccount



976
977
978
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 976

def 
  @service_account
end

#shielded_instance_configGoogle::Apis::TpuV2alpha1::ShieldedInstanceConfig

A set of Shielded Instance options. Corresponds to the JSON property shieldedInstanceConfig



981
982
983
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 981

def shielded_instance_config
  @shielded_instance_config
end

#stateString

Output only. The current state for the TPU Node. Corresponds to the JSON property state

Returns:

  • (String)


986
987
988
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 986

def state
  @state
end

#symptomsArray<Google::Apis::TpuV2alpha1::Symptom>

Output only. The Symptoms that have occurred to the TPU Node. Corresponds to the JSON property symptoms



991
992
993
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 991

def symptoms
  @symptoms
end

#tagsArray<String>

Tags to apply to the TPU Node. Tags are used to identify valid sources or targets for network firewalls. Corresponds to the JSON property tags

Returns:

  • (Array<String>)


997
998
999
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 997

def tags
  @tags
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 1004

def update!(**args)
  @accelerator_config = args[:accelerator_config] if args.key?(:accelerator_config)
  @accelerator_type = args[:accelerator_type] if args.key?(:accelerator_type)
  @api_version = args[:api_version] if args.key?(:api_version)
  @autocheckpoint_enabled = args[:autocheckpoint_enabled] if args.key?(:autocheckpoint_enabled)
  @boot_disk_config = args[:boot_disk_config] if args.key?(:boot_disk_config)
  @cidr_block = args[:cidr_block] if args.key?(:cidr_block)
  @create_time = args[:create_time] if args.key?(:create_time)
  @data_disks = args[:data_disks] if args.key?(:data_disks)
  @description = args[:description] if args.key?(:description)
  @health = args[:health] if args.key?(:health)
  @health_description = args[:health_description] if args.key?(:health_description)
  @id = args[:id] if args.key?(:id)
  @labels = args[:labels] if args.key?(:labels)
  @metadata = args[:metadata] if args.key?(:metadata)
  @multislice_node = args[:multislice_node] if args.key?(:multislice_node)
  @name = args[:name] if args.key?(:name)
  @network_config = args[:network_config] if args.key?(:network_config)
  @network_endpoints = args[:network_endpoints] if args.key?(:network_endpoints)
  @queued_resource = args[:queued_resource] if args.key?(:queued_resource)
  @runtime_version = args[:runtime_version] if args.key?(:runtime_version)
  @scheduling_config = args[:scheduling_config] if args.key?(:scheduling_config)
  @service_account = args[:service_account] if args.key?(:service_account)
  @shielded_instance_config = args[:shielded_instance_config] if args.key?(:shielded_instance_config)
  @state = args[:state] if args.key?(:state)
  @symptoms = args[:symptoms] if args.key?(:symptoms)
  @tags = args[:tags] if args.key?(:tags)
end