MetricSpec

case class MetricSpec(containerResource: Optional[ContainerResourceMetricSource], external: Optional[ExternalMetricSource], `object`: Optional[ObjectMetricSource], pods: Optional[PodsMetricSource], resource: Optional[ResourceMetricSource], `type`: String)

MetricSpec specifies how to scale based on a single metric (only type and one other matching field should be set at once).

Value Params
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. Note: "ContainerResource" type is available on when the feature-gate HPAContainerMetrics is enabled

Companion
object
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any

Value members

Concrete methods

Gets containerResource.

Gets containerResource.

If the field is not present, fails with com.coralogix.zio.k8s.client.UndefinedField.

Gets external.

Gets external.

If the field is not present, fails with com.coralogix.zio.k8s.client.UndefinedField.

Gets object.

Gets object.

If the field is not present, fails with com.coralogix.zio.k8s.client.UndefinedField.

Gets pods.

Gets pods.

If the field is not present, fails with com.coralogix.zio.k8s.client.UndefinedField.

Gets resource.

Gets resource.

If the field is not present, fails with com.coralogix.zio.k8s.client.UndefinedField.

def getType: IO[K8sFailure, String]

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. Note: "ContainerResource" type is available on when the feature-gate HPAContainerMetrics is enabled

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. Note: "ContainerResource" type is available on when the feature-gate HPAContainerMetrics is enabled

This effect always succeeds, it is safe to use the field type directly.

Inherited methods

def productElementNames: Iterator[String]
Inherited from
Product
def productIterator: Iterator[Any]
Inherited from
Product