Package com.google.cloud.compute.v1
Class AutoscalingPolicyScalingSchedule.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<AutoscalingPolicyScalingSchedule.Builder>
com.google.cloud.compute.v1.AutoscalingPolicyScalingSchedule.Builder
- All Implemented Interfaces:
AutoscalingPolicyScalingScheduleOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- AutoscalingPolicyScalingSchedule
public static final class AutoscalingPolicyScalingSchedule.Builder
extends com.google.protobuf.GeneratedMessage.Builder<AutoscalingPolicyScalingSchedule.Builder>
implements AutoscalingPolicyScalingScheduleOrBuilder
Scaling based on user-defined schedule. The message describes a single scaling schedule. A scaling schedule changes the minimum number of VM instances an autoscaler can recommend, which can trigger scaling out.Protobuf type
google.cloud.compute.v1.AutoscalingPolicyScalingSchedule-
Method Summary
Modifier and TypeMethodDescriptionbuild()clear()A description of a scaling schedule.A boolean value that specifies whether a scaling schedule can influence autoscaler recommendations.The duration of time intervals, in seconds, for which this scaling schedule is to run.The minimum number of VM instances that the autoscaler will recommend in time intervals starting according to schedule.The start timestamps of time intervals when this scaling schedule is to provide a scaling signal.The time zone to use when interpreting the schedule.A description of a scaling schedule.com.google.protobuf.ByteStringA description of a scaling schedule.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorbooleanA boolean value that specifies whether a scaling schedule can influence autoscaler recommendations.intThe duration of time intervals, in seconds, for which this scaling schedule is to run.intThe minimum number of VM instances that the autoscaler will recommend in time intervals starting according to schedule.The start timestamps of time intervals when this scaling schedule is to provide a scaling signal.com.google.protobuf.ByteStringThe start timestamps of time intervals when this scaling schedule is to provide a scaling signal.The time zone to use when interpreting the schedule.com.google.protobuf.ByteStringThe time zone to use when interpreting the schedule.booleanA description of a scaling schedule.booleanA boolean value that specifies whether a scaling schedule can influence autoscaler recommendations.booleanThe duration of time intervals, in seconds, for which this scaling schedule is to run.booleanThe minimum number of VM instances that the autoscaler will recommend in time intervals starting according to schedule.booleanThe start timestamps of time intervals when this scaling schedule is to provide a scaling signal.booleanThe time zone to use when interpreting the schedule.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanmergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) setDescription(String value) A description of a scaling schedule.setDescriptionBytes(com.google.protobuf.ByteString value) A description of a scaling schedule.setDisabled(boolean value) A boolean value that specifies whether a scaling schedule can influence autoscaler recommendations.setDurationSec(int value) The duration of time intervals, in seconds, for which this scaling schedule is to run.setMinRequiredReplicas(int value) The minimum number of VM instances that the autoscaler will recommend in time intervals starting according to schedule.setSchedule(String value) The start timestamps of time intervals when this scaling schedule is to provide a scaling signal.setScheduleBytes(com.google.protobuf.ByteString value) The start timestamps of time intervals when this scaling schedule is to provide a scaling signal.setTimeZone(String value) The time zone to use when interpreting the schedule.setTimeZoneBytes(com.google.protobuf.ByteString value) The time zone to use when interpreting the schedule.Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage.Builder<AutoscalingPolicyScalingSchedule.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessage.Builder<AutoscalingPolicyScalingSchedule.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessage.Builder<AutoscalingPolicyScalingSchedule.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<AutoscalingPolicyScalingSchedule.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<AutoscalingPolicyScalingSchedule.Builder>
-
mergeFrom
public AutoscalingPolicyScalingSchedule.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<AutoscalingPolicyScalingSchedule.Builder>- Throws:
IOException
-
hasDescription
public boolean hasDescription()A description of a scaling schedule.
optional string description = 422937596;- Specified by:
hasDescriptionin interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- Whether the description field is set.
-
getDescription
A description of a scaling schedule.
optional string description = 422937596;- Specified by:
getDescriptionin interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- The description.
-
getDescriptionBytes
public com.google.protobuf.ByteString getDescriptionBytes()A description of a scaling schedule.
optional string description = 422937596;- Specified by:
getDescriptionBytesin interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- The bytes for description.
-
setDescription
A description of a scaling schedule.
optional string description = 422937596;- Parameters:
value- The description to set.- Returns:
- This builder for chaining.
-
clearDescription
A description of a scaling schedule.
optional string description = 422937596;- Returns:
- This builder for chaining.
-
setDescriptionBytes
public AutoscalingPolicyScalingSchedule.Builder setDescriptionBytes(com.google.protobuf.ByteString value) A description of a scaling schedule.
optional string description = 422937596;- Parameters:
value- The bytes for description to set.- Returns:
- This builder for chaining.
-
hasDisabled
public boolean hasDisabled()A boolean value that specifies whether a scaling schedule can influence autoscaler recommendations. If set to true, then a scaling schedule has no effect. This field is optional, and its value is false by default.
optional bool disabled = 270940796;- Specified by:
hasDisabledin interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- Whether the disabled field is set.
-
getDisabled
public boolean getDisabled()A boolean value that specifies whether a scaling schedule can influence autoscaler recommendations. If set to true, then a scaling schedule has no effect. This field is optional, and its value is false by default.
optional bool disabled = 270940796;- Specified by:
getDisabledin interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- The disabled.
-
setDisabled
A boolean value that specifies whether a scaling schedule can influence autoscaler recommendations. If set to true, then a scaling schedule has no effect. This field is optional, and its value is false by default.
optional bool disabled = 270940796;- Parameters:
value- The disabled to set.- Returns:
- This builder for chaining.
-
clearDisabled
A boolean value that specifies whether a scaling schedule can influence autoscaler recommendations. If set to true, then a scaling schedule has no effect. This field is optional, and its value is false by default.
optional bool disabled = 270940796;- Returns:
- This builder for chaining.
-
hasDurationSec
public boolean hasDurationSec()The duration of time intervals, in seconds, for which this scaling schedule is to run. The minimum allowed value is 300. This field is required.
optional int32 duration_sec = 212356902;- Specified by:
hasDurationSecin interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- Whether the durationSec field is set.
-
getDurationSec
public int getDurationSec()The duration of time intervals, in seconds, for which this scaling schedule is to run. The minimum allowed value is 300. This field is required.
optional int32 duration_sec = 212356902;- Specified by:
getDurationSecin interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- The durationSec.
-
setDurationSec
The duration of time intervals, in seconds, for which this scaling schedule is to run. The minimum allowed value is 300. This field is required.
optional int32 duration_sec = 212356902;- Parameters:
value- The durationSec to set.- Returns:
- This builder for chaining.
-
clearDurationSec
The duration of time intervals, in seconds, for which this scaling schedule is to run. The minimum allowed value is 300. This field is required.
optional int32 duration_sec = 212356902;- Returns:
- This builder for chaining.
-
hasMinRequiredReplicas
public boolean hasMinRequiredReplicas()The minimum number of VM instances that the autoscaler will recommend in time intervals starting according to schedule. This field is required.
optional int32 min_required_replicas = 365514414;- Specified by:
hasMinRequiredReplicasin interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- Whether the minRequiredReplicas field is set.
-
getMinRequiredReplicas
public int getMinRequiredReplicas()The minimum number of VM instances that the autoscaler will recommend in time intervals starting according to schedule. This field is required.
optional int32 min_required_replicas = 365514414;- Specified by:
getMinRequiredReplicasin interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- The minRequiredReplicas.
-
setMinRequiredReplicas
The minimum number of VM instances that the autoscaler will recommend in time intervals starting according to schedule. This field is required.
optional int32 min_required_replicas = 365514414;- Parameters:
value- The minRequiredReplicas to set.- Returns:
- This builder for chaining.
-
clearMinRequiredReplicas
The minimum number of VM instances that the autoscaler will recommend in time intervals starting according to schedule. This field is required.
optional int32 min_required_replicas = 365514414;- Returns:
- This builder for chaining.
-
hasSchedule
public boolean hasSchedule()The start timestamps of time intervals when this scaling schedule is to provide a scaling signal. This field uses the extended cron format (with an optional year field). The expression can describe a single timestamp if the optional year is set, in which case the scaling schedule runs once. The schedule is interpreted with respect to time_zone. This field is required. Note: These timestamps only describe when autoscaler starts providing the scaling signal. The VMs need additional time to become serving.
optional string schedule = 375820951;- Specified by:
hasSchedulein interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- Whether the schedule field is set.
-
getSchedule
The start timestamps of time intervals when this scaling schedule is to provide a scaling signal. This field uses the extended cron format (with an optional year field). The expression can describe a single timestamp if the optional year is set, in which case the scaling schedule runs once. The schedule is interpreted with respect to time_zone. This field is required. Note: These timestamps only describe when autoscaler starts providing the scaling signal. The VMs need additional time to become serving.
optional string schedule = 375820951;- Specified by:
getSchedulein interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- The schedule.
-
getScheduleBytes
public com.google.protobuf.ByteString getScheduleBytes()The start timestamps of time intervals when this scaling schedule is to provide a scaling signal. This field uses the extended cron format (with an optional year field). The expression can describe a single timestamp if the optional year is set, in which case the scaling schedule runs once. The schedule is interpreted with respect to time_zone. This field is required. Note: These timestamps only describe when autoscaler starts providing the scaling signal. The VMs need additional time to become serving.
optional string schedule = 375820951;- Specified by:
getScheduleBytesin interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- The bytes for schedule.
-
setSchedule
The start timestamps of time intervals when this scaling schedule is to provide a scaling signal. This field uses the extended cron format (with an optional year field). The expression can describe a single timestamp if the optional year is set, in which case the scaling schedule runs once. The schedule is interpreted with respect to time_zone. This field is required. Note: These timestamps only describe when autoscaler starts providing the scaling signal. The VMs need additional time to become serving.
optional string schedule = 375820951;- Parameters:
value- The schedule to set.- Returns:
- This builder for chaining.
-
clearSchedule
The start timestamps of time intervals when this scaling schedule is to provide a scaling signal. This field uses the extended cron format (with an optional year field). The expression can describe a single timestamp if the optional year is set, in which case the scaling schedule runs once. The schedule is interpreted with respect to time_zone. This field is required. Note: These timestamps only describe when autoscaler starts providing the scaling signal. The VMs need additional time to become serving.
optional string schedule = 375820951;- Returns:
- This builder for chaining.
-
setScheduleBytes
public AutoscalingPolicyScalingSchedule.Builder setScheduleBytes(com.google.protobuf.ByteString value) The start timestamps of time intervals when this scaling schedule is to provide a scaling signal. This field uses the extended cron format (with an optional year field). The expression can describe a single timestamp if the optional year is set, in which case the scaling schedule runs once. The schedule is interpreted with respect to time_zone. This field is required. Note: These timestamps only describe when autoscaler starts providing the scaling signal. The VMs need additional time to become serving.
optional string schedule = 375820951;- Parameters:
value- The bytes for schedule to set.- Returns:
- This builder for chaining.
-
hasTimeZone
public boolean hasTimeZone()The time zone to use when interpreting the schedule. The value of this field must be a time zone name from the tz database: https://en.wikipedia.org/wiki/Tz_database. This field is assigned a default value of "UTC" if left empty.
optional string time_zone = 36848094;- Specified by:
hasTimeZonein interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- Whether the timeZone field is set.
-
getTimeZone
The time zone to use when interpreting the schedule. The value of this field must be a time zone name from the tz database: https://en.wikipedia.org/wiki/Tz_database. This field is assigned a default value of "UTC" if left empty.
optional string time_zone = 36848094;- Specified by:
getTimeZonein interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- The timeZone.
-
getTimeZoneBytes
public com.google.protobuf.ByteString getTimeZoneBytes()The time zone to use when interpreting the schedule. The value of this field must be a time zone name from the tz database: https://en.wikipedia.org/wiki/Tz_database. This field is assigned a default value of "UTC" if left empty.
optional string time_zone = 36848094;- Specified by:
getTimeZoneBytesin interfaceAutoscalingPolicyScalingScheduleOrBuilder- Returns:
- The bytes for timeZone.
-
setTimeZone
The time zone to use when interpreting the schedule. The value of this field must be a time zone name from the tz database: https://en.wikipedia.org/wiki/Tz_database. This field is assigned a default value of "UTC" if left empty.
optional string time_zone = 36848094;- Parameters:
value- The timeZone to set.- Returns:
- This builder for chaining.
-
clearTimeZone
The time zone to use when interpreting the schedule. The value of this field must be a time zone name from the tz database: https://en.wikipedia.org/wiki/Tz_database. This field is assigned a default value of "UTC" if left empty.
optional string time_zone = 36848094;- Returns:
- This builder for chaining.
-
setTimeZoneBytes
public AutoscalingPolicyScalingSchedule.Builder setTimeZoneBytes(com.google.protobuf.ByteString value) The time zone to use when interpreting the schedule. The value of this field must be a time zone name from the tz database: https://en.wikipedia.org/wiki/Tz_database. This field is assigned a default value of "UTC" if left empty.
optional string time_zone = 36848094;- Parameters:
value- The bytes for timeZone to set.- Returns:
- This builder for chaining.
-