Class: Google::Apis::TpuV2::QueuedResource
- Inherits:
-
Object
- Object
- Google::Apis::TpuV2::QueuedResource
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/tpu_v2/classes.rb,
lib/google/apis/tpu_v2/representations.rb,
lib/google/apis/tpu_v2/representations.rb
Overview
A QueuedResource represents a request for resources that will be placed in a queue and fulfilled when the necessary resources are available.
Instance Attribute Summary collapse
-
#create_time ⇒ String
Output only.
-
#guaranteed ⇒ Google::Apis::TpuV2::Guaranteed
Guaranteed tier definition.
-
#name ⇒ String
Output only.
-
#queueing_policy ⇒ Google::Apis::TpuV2::QueueingPolicy
Defines the policy of the QueuedRequest.
-
#reservation_name ⇒ String
Optional.
-
#spot ⇒ Google::Apis::TpuV2::Spot
Spot tier definition.
-
#state ⇒ Google::Apis::TpuV2::QueuedResourceState
QueuedResourceState defines the details of the QueuedResource request.
-
#tpu ⇒ Google::Apis::TpuV2::Tpu
Details of the TPU resource(s) being requested.
Instance Method Summary collapse
-
#initialize(**args) ⇒ QueuedResource
constructor
A new instance of QueuedResource.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ QueuedResource
Returns a new instance of QueuedResource.
1146 1147 1148 |
# File 'lib/google/apis/tpu_v2/classes.rb', line 1146 def initialize(**args) update!(**args) end |
Instance Attribute Details
#create_time ⇒ String
Output only. The time when the QueuedResource was created.
Corresponds to the JSON property createTime
1108 1109 1110 |
# File 'lib/google/apis/tpu_v2/classes.rb', line 1108 def create_time @create_time end |
#guaranteed ⇒ Google::Apis::TpuV2::Guaranteed
Guaranteed tier definition.
Corresponds to the JSON property guaranteed
1113 1114 1115 |
# File 'lib/google/apis/tpu_v2/classes.rb', line 1113 def guaranteed @guaranteed end |
#name ⇒ String
Output only. Immutable. The name of the QueuedResource.
Corresponds to the JSON property name
1118 1119 1120 |
# File 'lib/google/apis/tpu_v2/classes.rb', line 1118 def name @name end |
#queueing_policy ⇒ Google::Apis::TpuV2::QueueingPolicy
Defines the policy of the QueuedRequest.
Corresponds to the JSON property queueingPolicy
1123 1124 1125 |
# File 'lib/google/apis/tpu_v2/classes.rb', line 1123 def queueing_policy @queueing_policy end |
#reservation_name ⇒ String
Optional. Name of the reservation in which the resource should be provisioned.
Format: projects/project
/locations/zone
/reservations/reservation
Corresponds to the JSON property reservationName
1129 1130 1131 |
# File 'lib/google/apis/tpu_v2/classes.rb', line 1129 def reservation_name @reservation_name end |
#spot ⇒ Google::Apis::TpuV2::Spot
Spot tier definition.
Corresponds to the JSON property spot
1134 1135 1136 |
# File 'lib/google/apis/tpu_v2/classes.rb', line 1134 def spot @spot end |
#state ⇒ Google::Apis::TpuV2::QueuedResourceState
QueuedResourceState defines the details of the QueuedResource request.
Corresponds to the JSON property state
1139 1140 1141 |
# File 'lib/google/apis/tpu_v2/classes.rb', line 1139 def state @state end |
#tpu ⇒ Google::Apis::TpuV2::Tpu
Details of the TPU resource(s) being requested.
Corresponds to the JSON property tpu
1144 1145 1146 |
# File 'lib/google/apis/tpu_v2/classes.rb', line 1144 def tpu @tpu end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 |
# File 'lib/google/apis/tpu_v2/classes.rb', line 1151 def update!(**args) @create_time = args[:create_time] if args.key?(:create_time) @guaranteed = args[:guaranteed] if args.key?(:guaranteed) @name = args[:name] if args.key?(:name) @queueing_policy = args[:queueing_policy] if args.key?(:queueing_policy) @reservation_name = args[:reservation_name] if args.key?(:reservation_name) @spot = args[:spot] if args.key?(:spot) @state = args[:state] if args.key?(:state) @tpu = args[:tpu] if args.key?(:tpu) end |