Class MetricSpec
- java.lang.Object
-
- io.fabric8.kubernetes.api.model.autoscaling.v2.MetricSpec
-
- All Implemented Interfaces:
io.fabric8.kubernetes.api.builder.Editable<MetricSpecBuilder>,io.fabric8.kubernetes.api.model.KubernetesResource,Serializable
@Generated("io.fabric8.kubernetes.schema.generator.model.ModelGenerator") public class MetricSpec extends Object implements io.fabric8.kubernetes.api.builder.Editable<MetricSpecBuilder>, io.fabric8.kubernetes.api.model.KubernetesResource
MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MetricSpec()No args constructor for use in serializationMetricSpec(ContainerResourceMetricSource containerResource, ExternalMetricSource external, ObjectMetricSource object, PodsMetricSource pods, ResourceMetricSource resource, String type)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description MetricSpecBuilderedit()Map<String,Object>getAdditionalProperties()ContainerResourceMetricSourcegetContainerResource()MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).ExternalMetricSourcegetExternal()MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).ObjectMetricSourcegetObject()MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).PodsMetricSourcegetPods()MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).ResourceMetricSourcegetResource()MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).StringgetType()type is the type of metric source.voidsetAdditionalProperties(Map<String,Object> additionalProperties)voidsetAdditionalProperty(String name, Object value)voidsetContainerResource(ContainerResourceMetricSource containerResource)MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).voidsetExternal(ExternalMetricSource external)MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).voidsetObject(ObjectMetricSource object)MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).voidsetPods(PodsMetricSource pods)MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).voidsetResource(ResourceMetricSource resource)MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).voidsetType(String type)type is the type of metric source.MetricSpecBuildertoBuilder()
-
-
-
Constructor Detail
-
MetricSpec
public MetricSpec()
No args constructor for use in serialization
-
MetricSpec
public MetricSpec(ContainerResourceMetricSource containerResource, ExternalMetricSource external, ObjectMetricSource object, PodsMetricSource pods, ResourceMetricSource resource, String type)
-
-
Method Detail
-
getContainerResource
public ContainerResourceMetricSource getContainerResource()
MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).
-
setContainerResource
public void setContainerResource(ContainerResourceMetricSource containerResource)
MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).
-
getExternal
public ExternalMetricSource getExternal()
MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).
-
setExternal
public void setExternal(ExternalMetricSource external)
MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).
-
getObject
public ObjectMetricSource getObject()
MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).
-
setObject
public void setObject(ObjectMetricSource object)
MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).
-
getPods
public PodsMetricSource getPods()
MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).
-
setPods
public void setPods(PodsMetricSource pods)
MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).
-
getResource
public ResourceMetricSource getResource()
MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).
-
setResource
public void setResource(ResourceMetricSource resource)
MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).
-
getType
public String getType()
type is the type of metric source. It should be one of "ContainerResource", "External", "Object", "Pods" or "Resource", each mapping to a matching field in the object.
-
setType
public void setType(String type)
type is the type of metric source. It should be one of "ContainerResource", "External", "Object", "Pods" or "Resource", each mapping to a matching field in the object.
-
edit
public MetricSpecBuilder edit()
- Specified by:
editin interfaceio.fabric8.kubernetes.api.builder.Editable<MetricSpecBuilder>
-
toBuilder
public MetricSpecBuilder toBuilder()
-
-