Reference documentation and code samples for the Google Cloud Hypercompute Cluster V1 Client class NewSpotInstancesConfig.
When set in a ComputeResourceConfig, indicates that spot VM instances should be created.
Generated from protobuf message google.cloud.hypercomputecluster.v1.NewSpotInstancesConfig
Namespace
Google \ Cloud \ HypercomputeCluster \ V1Methods
__construct
Constructor.
| Parameters | |
|---|---|
| Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ zone |
string
Required. Immutable. Name of the zone in which VM instances should run, e.g., |
↳ machine_type |
string
Required. Immutable. Name of the Compute Engine machine type to use, e.g. |
↳ termination_action |
int
Optional. Termination action for the instance. If not specified, Compute Engine sets the termination action to DELETE. |
getZone
Required. Immutable. Name of the zone in which VM instances should run,
e.g., us-central1-a. Must be in the same region as the cluster, and must
match the zone of any other resources specified in the cluster.
| Returns | |
|---|---|
| Type | Description |
string |
|
setZone
Required. Immutable. Name of the zone in which VM instances should run,
e.g., us-central1-a. Must be in the same region as the cluster, and must
match the zone of any other resources specified in the cluster.
| Parameter | |
|---|---|
| Name | Description |
var |
string
|
| Returns | |
|---|---|
| Type | Description |
$this |
|
getMachineType
Required. Immutable. Name of the Compute Engine machine type to use, e.g.
n2-standard-2.
| Returns | |
|---|---|
| Type | Description |
string |
|
setMachineType
Required. Immutable. Name of the Compute Engine machine type to use, e.g.
n2-standard-2.
| Parameter | |
|---|---|
| Name | Description |
var |
string
|
| Returns | |
|---|---|
| Type | Description |
$this |
|
getTerminationAction
Optional. Termination action for the instance. If not specified, Compute Engine sets the termination action to DELETE.
| Returns | |
|---|---|
| Type | Description |
int |
Enum of type TerminationAction. |
setTerminationAction
Optional. Termination action for the instance. If not specified, Compute Engine sets the termination action to DELETE.
| Parameter | |
|---|---|
| Name | Description |
var |
int
Enum of type TerminationAction. |
| Returns | |
|---|---|
| Type | Description |
$this |
|