Package com.google.cloud.compute.v1
Class AutoscalingPolicyCpuUtilization.Builder
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite.Builder
-
- com.google.protobuf.AbstractMessage.Builder<BuilderT>
-
- com.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
- com.google.cloud.compute.v1.AutoscalingPolicyCpuUtilization.Builder
-
- All Implemented Interfaces:
AutoscalingPolicyCpuUtilizationOrBuilder
,com.google.protobuf.Message.Builder
,com.google.protobuf.MessageLite.Builder
,com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
,Cloneable
- Enclosing class:
- AutoscalingPolicyCpuUtilization
public static final class AutoscalingPolicyCpuUtilization.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder> implements AutoscalingPolicyCpuUtilizationOrBuilder
CPU utilization policy.
Protobuf typegoogle.cloud.compute.v1.AutoscalingPolicyCpuUtilization
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description AutoscalingPolicyCpuUtilization.Builder
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
AutoscalingPolicyCpuUtilization
build()
AutoscalingPolicyCpuUtilization
buildPartial()
AutoscalingPolicyCpuUtilization.Builder
clear()
AutoscalingPolicyCpuUtilization.Builder
clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
AutoscalingPolicyCpuUtilization.Builder
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
AutoscalingPolicyCpuUtilization.Builder
clearPredictiveMethod()
Indicates whether predictive autoscaling based on CPU metric is enabled.AutoscalingPolicyCpuUtilization.Builder
clearUtilizationTarget()
The target CPU utilization that the autoscaler maintains.AutoscalingPolicyCpuUtilization.Builder
clone()
AutoscalingPolicyCpuUtilization
getDefaultInstanceForType()
static com.google.protobuf.Descriptors.Descriptor
getDescriptor()
com.google.protobuf.Descriptors.Descriptor
getDescriptorForType()
String
getPredictiveMethod()
Indicates whether predictive autoscaling based on CPU metric is enabled.com.google.protobuf.ByteString
getPredictiveMethodBytes()
Indicates whether predictive autoscaling based on CPU metric is enabled.double
getUtilizationTarget()
The target CPU utilization that the autoscaler maintains.boolean
hasPredictiveMethod()
Indicates whether predictive autoscaling based on CPU metric is enabled.boolean
hasUtilizationTarget()
The target CPU utilization that the autoscaler maintains.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()
boolean
isInitialized()
AutoscalingPolicyCpuUtilization.Builder
mergeFrom(AutoscalingPolicyCpuUtilization other)
AutoscalingPolicyCpuUtilization.Builder
mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
AutoscalingPolicyCpuUtilization.Builder
mergeFrom(com.google.protobuf.Message other)
AutoscalingPolicyCpuUtilization.Builder
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
AutoscalingPolicyCpuUtilization.Builder
setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
AutoscalingPolicyCpuUtilization.Builder
setPredictiveMethod(String value)
Indicates whether predictive autoscaling based on CPU metric is enabled.AutoscalingPolicyCpuUtilization.Builder
setPredictiveMethodBytes(com.google.protobuf.ByteString value)
Indicates whether predictive autoscaling based on CPU metric is enabled.AutoscalingPolicyCpuUtilization.Builder
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
AutoscalingPolicyCpuUtilization.Builder
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
AutoscalingPolicyCpuUtilization.Builder
setUtilizationTarget(double value)
The target CPU utilization that the autoscaler maintains.-
Methods inherited from class com.google.protobuf.GeneratedMessageV3.Builder
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMutableMapField, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3
-
Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
-
-
-
Method Detail
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
- Specified by:
internalGetFieldAccessorTable
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
clear
public AutoscalingPolicyCpuUtilization.Builder clear()
- Specified by:
clear
in interfacecom.google.protobuf.Message.Builder
- Specified by:
clear
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
clear
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.Message.Builder
- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.MessageOrBuilder
- Overrides:
getDescriptorForType
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
getDefaultInstanceForType
public AutoscalingPolicyCpuUtilization getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageOrBuilder
-
build
public AutoscalingPolicyCpuUtilization build()
- Specified by:
build
in interfacecom.google.protobuf.Message.Builder
- Specified by:
build
in interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
public AutoscalingPolicyCpuUtilization buildPartial()
- Specified by:
buildPartial
in interfacecom.google.protobuf.Message.Builder
- Specified by:
buildPartial
in interfacecom.google.protobuf.MessageLite.Builder
-
clone
public AutoscalingPolicyCpuUtilization.Builder clone()
- Specified by:
clone
in interfacecom.google.protobuf.Message.Builder
- Specified by:
clone
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
clone
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
setField
public AutoscalingPolicyCpuUtilization.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
- Specified by:
setField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setField
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
clearField
public AutoscalingPolicyCpuUtilization.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
- Specified by:
clearField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
clearField
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
clearOneof
public AutoscalingPolicyCpuUtilization.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
- Specified by:
clearOneof
in interfacecom.google.protobuf.Message.Builder
- Overrides:
clearOneof
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
setRepeatedField
public AutoscalingPolicyCpuUtilization.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
- Specified by:
setRepeatedField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setRepeatedField
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
addRepeatedField
public AutoscalingPolicyCpuUtilization.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
- Specified by:
addRepeatedField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
addRepeatedField
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
mergeFrom
public AutoscalingPolicyCpuUtilization.Builder mergeFrom(com.google.protobuf.Message other)
- Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
mergeFrom
public AutoscalingPolicyCpuUtilization.Builder mergeFrom(AutoscalingPolicyCpuUtilization other)
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitialized
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Overrides:
isInitialized
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
mergeFrom
public AutoscalingPolicyCpuUtilization.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Specified by:
mergeFrom
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<AutoscalingPolicyCpuUtilization.Builder>
- Throws:
IOException
-
hasPredictiveMethod
public boolean hasPredictiveMethod()
Indicates whether predictive autoscaling based on CPU metric is enabled. Valid values are: * NONE (default). No predictive method is used. The autoscaler scales the group to meet current demand based on real-time metrics. * OPTIMIZE_AVAILABILITY. Predictive autoscaling improves availability by monitoring daily and weekly load patterns and scaling out ahead of anticipated demand. Check the PredictiveMethod enum for the list of possible values.
optional string predictive_method = 390220737;
- Specified by:
hasPredictiveMethod
in interfaceAutoscalingPolicyCpuUtilizationOrBuilder
- Returns:
- Whether the predictiveMethod field is set.
-
getPredictiveMethod
public String getPredictiveMethod()
Indicates whether predictive autoscaling based on CPU metric is enabled. Valid values are: * NONE (default). No predictive method is used. The autoscaler scales the group to meet current demand based on real-time metrics. * OPTIMIZE_AVAILABILITY. Predictive autoscaling improves availability by monitoring daily and weekly load patterns and scaling out ahead of anticipated demand. Check the PredictiveMethod enum for the list of possible values.
optional string predictive_method = 390220737;
- Specified by:
getPredictiveMethod
in interfaceAutoscalingPolicyCpuUtilizationOrBuilder
- Returns:
- The predictiveMethod.
-
getPredictiveMethodBytes
public com.google.protobuf.ByteString getPredictiveMethodBytes()
Indicates whether predictive autoscaling based on CPU metric is enabled. Valid values are: * NONE (default). No predictive method is used. The autoscaler scales the group to meet current demand based on real-time metrics. * OPTIMIZE_AVAILABILITY. Predictive autoscaling improves availability by monitoring daily and weekly load patterns and scaling out ahead of anticipated demand. Check the PredictiveMethod enum for the list of possible values.
optional string predictive_method = 390220737;
- Specified by:
getPredictiveMethodBytes
in interfaceAutoscalingPolicyCpuUtilizationOrBuilder
- Returns:
- The bytes for predictiveMethod.
-
setPredictiveMethod
public AutoscalingPolicyCpuUtilization.Builder setPredictiveMethod(String value)
Indicates whether predictive autoscaling based on CPU metric is enabled. Valid values are: * NONE (default). No predictive method is used. The autoscaler scales the group to meet current demand based on real-time metrics. * OPTIMIZE_AVAILABILITY. Predictive autoscaling improves availability by monitoring daily and weekly load patterns and scaling out ahead of anticipated demand. Check the PredictiveMethod enum for the list of possible values.
optional string predictive_method = 390220737;
- Parameters:
value
- The predictiveMethod to set.- Returns:
- This builder for chaining.
-
clearPredictiveMethod
public AutoscalingPolicyCpuUtilization.Builder clearPredictiveMethod()
Indicates whether predictive autoscaling based on CPU metric is enabled. Valid values are: * NONE (default). No predictive method is used. The autoscaler scales the group to meet current demand based on real-time metrics. * OPTIMIZE_AVAILABILITY. Predictive autoscaling improves availability by monitoring daily and weekly load patterns and scaling out ahead of anticipated demand. Check the PredictiveMethod enum for the list of possible values.
optional string predictive_method = 390220737;
- Returns:
- This builder for chaining.
-
setPredictiveMethodBytes
public AutoscalingPolicyCpuUtilization.Builder setPredictiveMethodBytes(com.google.protobuf.ByteString value)
Indicates whether predictive autoscaling based on CPU metric is enabled. Valid values are: * NONE (default). No predictive method is used. The autoscaler scales the group to meet current demand based on real-time metrics. * OPTIMIZE_AVAILABILITY. Predictive autoscaling improves availability by monitoring daily and weekly load patterns and scaling out ahead of anticipated demand. Check the PredictiveMethod enum for the list of possible values.
optional string predictive_method = 390220737;
- Parameters:
value
- The bytes for predictiveMethod to set.- Returns:
- This builder for chaining.
-
hasUtilizationTarget
public boolean hasUtilizationTarget()
The target CPU utilization that the autoscaler maintains. Must be a float value in the range (0, 1]. If not specified, the default is 0.6. If the CPU level is below the target utilization, the autoscaler scales in the number of instances until it reaches the minimum number of instances you specified or until the average CPU of your instances reaches the target utilization. If the average CPU is above the target utilization, the autoscaler scales out until it reaches the maximum number of instances you specified or until the average utilization reaches the target utilization.
optional double utilization_target = 215905870;
- Specified by:
hasUtilizationTarget
in interfaceAutoscalingPolicyCpuUtilizationOrBuilder
- Returns:
- Whether the utilizationTarget field is set.
-
getUtilizationTarget
public double getUtilizationTarget()
The target CPU utilization that the autoscaler maintains. Must be a float value in the range (0, 1]. If not specified, the default is 0.6. If the CPU level is below the target utilization, the autoscaler scales in the number of instances until it reaches the minimum number of instances you specified or until the average CPU of your instances reaches the target utilization. If the average CPU is above the target utilization, the autoscaler scales out until it reaches the maximum number of instances you specified or until the average utilization reaches the target utilization.
optional double utilization_target = 215905870;
- Specified by:
getUtilizationTarget
in interfaceAutoscalingPolicyCpuUtilizationOrBuilder
- Returns:
- The utilizationTarget.
-
setUtilizationTarget
public AutoscalingPolicyCpuUtilization.Builder setUtilizationTarget(double value)
The target CPU utilization that the autoscaler maintains. Must be a float value in the range (0, 1]. If not specified, the default is 0.6. If the CPU level is below the target utilization, the autoscaler scales in the number of instances until it reaches the minimum number of instances you specified or until the average CPU of your instances reaches the target utilization. If the average CPU is above the target utilization, the autoscaler scales out until it reaches the maximum number of instances you specified or until the average utilization reaches the target utilization.
optional double utilization_target = 215905870;
- Parameters:
value
- The utilizationTarget to set.- Returns:
- This builder for chaining.
-
clearUtilizationTarget
public AutoscalingPolicyCpuUtilization.Builder clearUtilizationTarget()
The target CPU utilization that the autoscaler maintains. Must be a float value in the range (0, 1]. If not specified, the default is 0.6. If the CPU level is below the target utilization, the autoscaler scales in the number of instances until it reaches the minimum number of instances you specified or until the average CPU of your instances reaches the target utilization. If the average CPU is above the target utilization, the autoscaler scales out until it reaches the maximum number of instances you specified or until the average utilization reaches the target utilization.
optional double utilization_target = 215905870;
- Returns:
- This builder for chaining.
-
setUnknownFields
public final AutoscalingPolicyCpuUtilization.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
setUnknownFields
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setUnknownFields
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
mergeUnknownFields
public final AutoscalingPolicyCpuUtilization.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
mergeUnknownFields
in interfacecom.google.protobuf.Message.Builder
- Overrides:
mergeUnknownFields
in classcom.google.protobuf.GeneratedMessageV3.Builder<AutoscalingPolicyCpuUtilization.Builder>
-
-