public final class Scheduling extends GeneratedMessageV3 implements SchedulingOrBuilder
Sets the scheduling options for an Instance. NextID: 21
Protobuf type google.cloud.compute.v1.Scheduling
Static Fields
AUTOMATIC_RESTART_FIELD_NUMBER
public static final int AUTOMATIC_RESTART_FIELD_NUMBER
Field Value
INSTANCE_TERMINATION_ACTION_FIELD_NUMBER
public static final int INSTANCE_TERMINATION_ACTION_FIELD_NUMBER
Field Value
LOCATION_HINT_FIELD_NUMBER
public static final int LOCATION_HINT_FIELD_NUMBER
Field Value
MIN_NODE_CPUS_FIELD_NUMBER
public static final int MIN_NODE_CPUS_FIELD_NUMBER
Field Value
NODE_AFFINITIES_FIELD_NUMBER
public static final int NODE_AFFINITIES_FIELD_NUMBER
Field Value
ON_HOST_MAINTENANCE_FIELD_NUMBER
public static final int ON_HOST_MAINTENANCE_FIELD_NUMBER
Field Value
PREEMPTIBLE_FIELD_NUMBER
public static final int PREEMPTIBLE_FIELD_NUMBER
Field Value
PROVISIONING_MODEL_FIELD_NUMBER
public static final int PROVISIONING_MODEL_FIELD_NUMBER
Field Value
Static Methods
getDefaultInstance()
public static Scheduling getDefaultInstance()
Returns
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
newBuilder()
public static Scheduling.Builder newBuilder()
Returns
newBuilder(Scheduling prototype)
public static Scheduling.Builder newBuilder(Scheduling prototype)
Parameter
Returns
public static Scheduling parseDelimitedFrom(InputStream input)
Parameter
Returns
Exceptions
public static Scheduling parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(byte[] data)
public static Scheduling parseFrom(byte[] data)
Parameter
Name | Description |
data | byte[]
|
Returns
Exceptions
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static Scheduling parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteString data)
public static Scheduling parseFrom(ByteString data)
Parameter
Returns
Exceptions
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static Scheduling parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static Scheduling parseFrom(CodedInputStream input)
Parameter
Returns
Exceptions
public static Scheduling parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static Scheduling parseFrom(InputStream input)
Parameter
Returns
Exceptions
public static Scheduling parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteBuffer data)
public static Scheduling parseFrom(ByteBuffer data)
Parameter
Returns
Exceptions
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static Scheduling parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parser()
public static Parser<Scheduling> parser()
Returns
Methods
equals(Object obj)
public boolean equals(Object obj)
Parameter
Returns
Overrides
getAutomaticRestart()
public boolean getAutomaticRestart()
Specifies whether the instance should be automatically restarted if it is terminated by Compute Engine (not terminated by a user). You can only set the automatic restart option for standard instances. Preemptible instances cannot be automatically restarted. By default, this is set to true so an instance is automatically restarted if it is terminated by Compute Engine.
optional bool automatic_restart = 350821371;
Returns
Type | Description |
boolean | The automaticRestart.
|
getDefaultInstanceForType()
public Scheduling getDefaultInstanceForType()
Returns
getInstanceTerminationAction()
public String getInstanceTerminationAction()
Specifies the termination action for the instance.
Check the InstanceTerminationAction enum for the list of possible values.
optional string instance_termination_action = 107380667;
Returns
Type | Description |
String | The instanceTerminationAction.
|
getInstanceTerminationActionBytes()
public ByteString getInstanceTerminationActionBytes()
Specifies the termination action for the instance.
Check the InstanceTerminationAction enum for the list of possible values.
optional string instance_termination_action = 107380667;
Returns
Type | Description |
ByteString | The bytes for instanceTerminationAction.
|
getLocationHint()
public String getLocationHint()
An opaque location hint used to place the instance close to other resources. This field is for use by internal tools that use the public API.
optional string location_hint = 350519505;
Returns
Type | Description |
String | The locationHint.
|
getLocationHintBytes()
public ByteString getLocationHintBytes()
An opaque location hint used to place the instance close to other resources. This field is for use by internal tools that use the public API.
optional string location_hint = 350519505;
Returns
Type | Description |
ByteString | The bytes for locationHint.
|
getMinNodeCpus()
public int getMinNodeCpus()
The minimum number of virtual CPUs this instance will consume when running on a sole-tenant node.
optional int32 min_node_cpus = 317231675;
Returns
Type | Description |
int | The minNodeCpus.
|
getNodeAffinities(int index)
public SchedulingNodeAffinity getNodeAffinities(int index)
A set of node affinity and anti-affinity configurations. Refer to Configuring node affinity for more information. Overrides reservationAffinity.
repeated .google.cloud.compute.v1.SchedulingNodeAffinity node_affinities = 461799971;
Parameter
Returns
getNodeAffinitiesCount()
public int getNodeAffinitiesCount()
A set of node affinity and anti-affinity configurations. Refer to Configuring node affinity for more information. Overrides reservationAffinity.
repeated .google.cloud.compute.v1.SchedulingNodeAffinity node_affinities = 461799971;
Returns
getNodeAffinitiesList()
public List<SchedulingNodeAffinity> getNodeAffinitiesList()
A set of node affinity and anti-affinity configurations. Refer to Configuring node affinity for more information. Overrides reservationAffinity.
repeated .google.cloud.compute.v1.SchedulingNodeAffinity node_affinities = 461799971;
Returns
getNodeAffinitiesOrBuilder(int index)
public SchedulingNodeAffinityOrBuilder getNodeAffinitiesOrBuilder(int index)
A set of node affinity and anti-affinity configurations. Refer to Configuring node affinity for more information. Overrides reservationAffinity.
repeated .google.cloud.compute.v1.SchedulingNodeAffinity node_affinities = 461799971;
Parameter
Returns
getNodeAffinitiesOrBuilderList()
public List<? extends SchedulingNodeAffinityOrBuilder> getNodeAffinitiesOrBuilderList()
A set of node affinity and anti-affinity configurations. Refer to Configuring node affinity for more information. Overrides reservationAffinity.
repeated .google.cloud.compute.v1.SchedulingNodeAffinity node_affinities = 461799971;
Returns
Type | Description |
List<? extends com.google.cloud.compute.v1.SchedulingNodeAffinityOrBuilder> | |
getOnHostMaintenance()
public String getOnHostMaintenance()
Defines the maintenance behavior for this instance. For standard instances, the default behavior is MIGRATE. For preemptible instances, the default and only possible behavior is TERMINATE. For more information, see Set VM availability policies.
Check the OnHostMaintenance enum for the list of possible values.
optional string on_host_maintenance = 64616796;
Returns
Type | Description |
String | The onHostMaintenance.
|
getOnHostMaintenanceBytes()
public ByteString getOnHostMaintenanceBytes()
Defines the maintenance behavior for this instance. For standard instances, the default behavior is MIGRATE. For preemptible instances, the default and only possible behavior is TERMINATE. For more information, see Set VM availability policies.
Check the OnHostMaintenance enum for the list of possible values.
optional string on_host_maintenance = 64616796;
Returns
Type | Description |
ByteString | The bytes for onHostMaintenance.
|
getParserForType()
public Parser<Scheduling> getParserForType()
Returns
Overrides
getPreemptible()
public boolean getPreemptible()
Defines whether the instance is preemptible. This can only be set during instance creation or while the instance is stopped and therefore, in a TERMINATED
state. See Instance Life Cycle for more information on the possible instance states.
optional bool preemptible = 324203169;
Returns
Type | Description |
boolean | The preemptible.
|
getProvisioningModel()
public String getProvisioningModel()
Specifies the provisioning model of the instance.
Check the ProvisioningModel enum for the list of possible values.
optional string provisioning_model = 494423;
Returns
Type | Description |
String | The provisioningModel.
|
getProvisioningModelBytes()
public ByteString getProvisioningModelBytes()
Specifies the provisioning model of the instance.
Check the ProvisioningModel enum for the list of possible values.
optional string provisioning_model = 494423;
Returns
Type | Description |
ByteString | The bytes for provisioningModel.
|
getSerializedSize()
public int getSerializedSize()
Returns
Overrides
getUnknownFields()
public final UnknownFieldSet getUnknownFields()
Returns
Overrides
hasAutomaticRestart()
public boolean hasAutomaticRestart()
Specifies whether the instance should be automatically restarted if it is terminated by Compute Engine (not terminated by a user). You can only set the automatic restart option for standard instances. Preemptible instances cannot be automatically restarted. By default, this is set to true so an instance is automatically restarted if it is terminated by Compute Engine.
optional bool automatic_restart = 350821371;
Returns
Type | Description |
boolean | Whether the automaticRestart field is set.
|
hasInstanceTerminationAction()
public boolean hasInstanceTerminationAction()
Specifies the termination action for the instance.
Check the InstanceTerminationAction enum for the list of possible values.
optional string instance_termination_action = 107380667;
Returns
Type | Description |
boolean | Whether the instanceTerminationAction field is set.
|
hasLocationHint()
public boolean hasLocationHint()
An opaque location hint used to place the instance close to other resources. This field is for use by internal tools that use the public API.
optional string location_hint = 350519505;
Returns
Type | Description |
boolean | Whether the locationHint field is set.
|
hasMinNodeCpus()
public boolean hasMinNodeCpus()
The minimum number of virtual CPUs this instance will consume when running on a sole-tenant node.
optional int32 min_node_cpus = 317231675;
Returns
Type | Description |
boolean | Whether the minNodeCpus field is set.
|
hasOnHostMaintenance()
public boolean hasOnHostMaintenance()
Defines the maintenance behavior for this instance. For standard instances, the default behavior is MIGRATE. For preemptible instances, the default and only possible behavior is TERMINATE. For more information, see Set VM availability policies.
Check the OnHostMaintenance enum for the list of possible values.
optional string on_host_maintenance = 64616796;
Returns
Type | Description |
boolean | Whether the onHostMaintenance field is set.
|
hasPreemptible()
public boolean hasPreemptible()
Defines whether the instance is preemptible. This can only be set during instance creation or while the instance is stopped and therefore, in a TERMINATED
state. See Instance Life Cycle for more information on the possible instance states.
optional bool preemptible = 324203169;
Returns
Type | Description |
boolean | Whether the preemptible field is set.
|
hasProvisioningModel()
public boolean hasProvisioningModel()
Specifies the provisioning model of the instance.
Check the ProvisioningModel enum for the list of possible values.
optional string provisioning_model = 494423;
Returns
Type | Description |
boolean | Whether the provisioningModel field is set.
|
hashCode()
Returns
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
newBuilderForType()
public Scheduling.Builder newBuilderForType()
Returns
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected Scheduling.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Returns
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Returns
Overrides
toBuilder()
public Scheduling.Builder toBuilder()
Returns
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Parameter
Overrides
Exceptions