Class V1Autoscaling.ResourceMetricSource.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderType>
com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
io.kubernetes.client.proto.V1Autoscaling.ResourceMetricSource.Builder
All Implemented Interfaces:
com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, V1Autoscaling.ResourceMetricSourceOrBuilder, Cloneable
Enclosing class:
V1Autoscaling.ResourceMetricSource

public static final class V1Autoscaling.ResourceMetricSource.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder> implements V1Autoscaling.ResourceMetricSourceOrBuilder
 ResourceMetricSource indicates how to scale on a resource metric known to
 Kubernetes, as specified in requests and limits, describing each pod in the
 current scale target (e.g. CPU or memory).  The values will be averaged
 together before being compared to the target.  Such metrics are built in to
 Kubernetes, and have special scaling options on top of those available to
 normal per-pod metrics using the "pods" source.  Only one "target" type
 should be set.
 
Protobuf type k8s.io.api.autoscaling.v1.ResourceMetricSource
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • clear

      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • getDefaultInstanceForType

      public V1Autoscaling.ResourceMetricSource getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public V1Autoscaling.ResourceMetricSource buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • clone

      Specified by:
      clone in interface com.google.protobuf.Message.Builder
      Specified by:
      clone in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clone in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • setField

      public V1Autoscaling.ResourceMetricSource.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      setField in interface com.google.protobuf.Message.Builder
      Overrides:
      setField in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • clearField

      public V1Autoscaling.ResourceMetricSource.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
      Specified by:
      clearField in interface com.google.protobuf.Message.Builder
      Overrides:
      clearField in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • clearOneof

      public V1Autoscaling.ResourceMetricSource.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
      Specified by:
      clearOneof in interface com.google.protobuf.Message.Builder
      Overrides:
      clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • setRepeatedField

      public V1Autoscaling.ResourceMetricSource.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
      Specified by:
      setRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • addRepeatedField

      public V1Autoscaling.ResourceMetricSource.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      addRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • mergeFrom

      public V1Autoscaling.ResourceMetricSource.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • mergeFrom

      public V1Autoscaling.ResourceMetricSource.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<V1Autoscaling.ResourceMetricSource.Builder>
      Throws:
      IOException
    • hasName

      public boolean hasName()
       name is the name of the resource in question.
       
      optional string name = 1;
      Specified by:
      hasName in interface V1Autoscaling.ResourceMetricSourceOrBuilder
    • getName

      public String getName()
       name is the name of the resource in question.
       
      optional string name = 1;
      Specified by:
      getName in interface V1Autoscaling.ResourceMetricSourceOrBuilder
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       name is the name of the resource in question.
       
      optional string name = 1;
      Specified by:
      getNameBytes in interface V1Autoscaling.ResourceMetricSourceOrBuilder
    • setName

       name is the name of the resource in question.
       
      optional string name = 1;
    • clearName

       name is the name of the resource in question.
       
      optional string name = 1;
    • setNameBytes

      public V1Autoscaling.ResourceMetricSource.Builder setNameBytes(com.google.protobuf.ByteString value)
       name is the name of the resource in question.
       
      optional string name = 1;
    • hasTargetAverageUtilization

      public boolean hasTargetAverageUtilization()
       targetAverageUtilization is the target value of the average of the
       resource metric across all relevant pods, represented as a percentage of
       the requested value of the resource for the pods.
       +optional
       
      optional int32 targetAverageUtilization = 2;
      Specified by:
      hasTargetAverageUtilization in interface V1Autoscaling.ResourceMetricSourceOrBuilder
    • getTargetAverageUtilization

      public int getTargetAverageUtilization()
       targetAverageUtilization is the target value of the average of the
       resource metric across all relevant pods, represented as a percentage of
       the requested value of the resource for the pods.
       +optional
       
      optional int32 targetAverageUtilization = 2;
      Specified by:
      getTargetAverageUtilization in interface V1Autoscaling.ResourceMetricSourceOrBuilder
    • setTargetAverageUtilization

      public V1Autoscaling.ResourceMetricSource.Builder setTargetAverageUtilization(int value)
       targetAverageUtilization is the target value of the average of the
       resource metric across all relevant pods, represented as a percentage of
       the requested value of the resource for the pods.
       +optional
       
      optional int32 targetAverageUtilization = 2;
    • clearTargetAverageUtilization

      public V1Autoscaling.ResourceMetricSource.Builder clearTargetAverageUtilization()
       targetAverageUtilization is the target value of the average of the
       resource metric across all relevant pods, represented as a percentage of
       the requested value of the resource for the pods.
       +optional
       
      optional int32 targetAverageUtilization = 2;
    • hasTargetAverageValue

      public boolean hasTargetAverageValue()
       targetAverageValue is the target value of the average of the
       resource metric across all relevant pods, as a raw value (instead of as
       a percentage of the request), similar to the "pods" metric source type.
       +optional
       
      optional .k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 3;
      Specified by:
      hasTargetAverageValue in interface V1Autoscaling.ResourceMetricSourceOrBuilder
    • getTargetAverageValue

      public Resource.Quantity getTargetAverageValue()
       targetAverageValue is the target value of the average of the
       resource metric across all relevant pods, as a raw value (instead of as
       a percentage of the request), similar to the "pods" metric source type.
       +optional
       
      optional .k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 3;
      Specified by:
      getTargetAverageValue in interface V1Autoscaling.ResourceMetricSourceOrBuilder
    • setTargetAverageValue

      public V1Autoscaling.ResourceMetricSource.Builder setTargetAverageValue(Resource.Quantity value)
       targetAverageValue is the target value of the average of the
       resource metric across all relevant pods, as a raw value (instead of as
       a percentage of the request), similar to the "pods" metric source type.
       +optional
       
      optional .k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 3;
    • setTargetAverageValue

      public V1Autoscaling.ResourceMetricSource.Builder setTargetAverageValue(Resource.Quantity.Builder builderForValue)
       targetAverageValue is the target value of the average of the
       resource metric across all relevant pods, as a raw value (instead of as
       a percentage of the request), similar to the "pods" metric source type.
       +optional
       
      optional .k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 3;
    • mergeTargetAverageValue

      public V1Autoscaling.ResourceMetricSource.Builder mergeTargetAverageValue(Resource.Quantity value)
       targetAverageValue is the target value of the average of the
       resource metric across all relevant pods, as a raw value (instead of as
       a percentage of the request), similar to the "pods" metric source type.
       +optional
       
      optional .k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 3;
    • clearTargetAverageValue

      public V1Autoscaling.ResourceMetricSource.Builder clearTargetAverageValue()
       targetAverageValue is the target value of the average of the
       resource metric across all relevant pods, as a raw value (instead of as
       a percentage of the request), similar to the "pods" metric source type.
       +optional
       
      optional .k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 3;
    • getTargetAverageValueBuilder

      public Resource.Quantity.Builder getTargetAverageValueBuilder()
       targetAverageValue is the target value of the average of the
       resource metric across all relevant pods, as a raw value (instead of as
       a percentage of the request), similar to the "pods" metric source type.
       +optional
       
      optional .k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 3;
    • getTargetAverageValueOrBuilder

      public Resource.QuantityOrBuilder getTargetAverageValueOrBuilder()
       targetAverageValue is the target value of the average of the
       resource metric across all relevant pods, as a raw value (instead of as
       a percentage of the request), similar to the "pods" metric source type.
       +optional
       
      optional .k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 3;
      Specified by:
      getTargetAverageValueOrBuilder in interface V1Autoscaling.ResourceMetricSourceOrBuilder
    • setUnknownFields

      public final V1Autoscaling.ResourceMetricSource.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      setUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>
    • mergeUnknownFields

      public final V1Autoscaling.ResourceMetricSource.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      mergeUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<V1Autoscaling.ResourceMetricSource.Builder>