Compute V1 Client - Class ResourcePolicyGroupPlacementPolicy (1.8.3)

Reference documentation and code samples for the Compute V1 Client class ResourcePolicyGroupPlacementPolicy.

A GroupPlacementPolicy specifies resource placement configuration. It specifies the failure bucket separation as well as network locality

Generated from protobuf message google.cloud.compute.v1.ResourcePolicyGroupPlacementPolicy

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ availability_domain_count int

The number of availability domains to spread instances across. If two instances are in different availability domain, they are not in the same low latency network.

↳ collocation string

Specifies network collocation Check the Collocation enum for the list of possible values.

↳ vm_count int

Number of VMs in this placement group. Google does not recommend that you use this field unless you use a compact policy and you want your policy to work only if it contains this exact number of VMs.

getAvailabilityDomainCount

The number of availability domains to spread instances across. If two instances are in different availability domain, they are not in the same low latency network.

Returns
TypeDescription
int

hasAvailabilityDomainCount

clearAvailabilityDomainCount

setAvailabilityDomainCount

The number of availability domains to spread instances across. If two instances are in different availability domain, they are not in the same low latency network.

Parameter
NameDescription
var int
Returns
TypeDescription
$this

getCollocation

Specifies network collocation Check the Collocation enum for the list of possible values.

Returns
TypeDescription
string

hasCollocation

clearCollocation

setCollocation

Specifies network collocation Check the Collocation enum for the list of possible values.

Parameter
NameDescription
var string
Returns
TypeDescription
$this

getVmCount

Number of VMs in this placement group. Google does not recommend that you use this field unless you use a compact policy and you want your policy to work only if it contains this exact number of VMs.

Returns
TypeDescription
int

hasVmCount

clearVmCount

setVmCount

Number of VMs in this placement group. Google does not recommend that you use this field unless you use a compact policy and you want your policy to work only if it contains this exact number of VMs.

Parameter
NameDescription
var int
Returns
TypeDescription
$this