Class: Google::Apis::TpuV1::SchedulingConfig

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

Overview

Sets the scheduling options for this node.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ SchedulingConfig

Returns a new instance of SchedulingConfig.



583
584
585
# File 'lib/google/apis/tpu_v1/classes.rb', line 583

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

Instance Attribute Details

#preemptibleBoolean Also known as: preemptible?

Defines whether the node is preemptible. Corresponds to the JSON property preemptible

Returns:

  • (Boolean)


574
575
576
# File 'lib/google/apis/tpu_v1/classes.rb', line 574

def preemptible
  @preemptible
end

#reservedBoolean Also known as: reserved?

Whether the node is created under a reservation. Corresponds to the JSON property reserved

Returns:

  • (Boolean)


580
581
582
# File 'lib/google/apis/tpu_v1/classes.rb', line 580

def reserved
  @reserved
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



588
589
590
591
# File 'lib/google/apis/tpu_v1/classes.rb', line 588

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