All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.kubernetes.autoscaling.v2beta1.inputs.ObjectMetricSourcePatchArgs Maven / Gradle / Ivy

// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.kubernetes.autoscaling.v2beta1.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.kubernetes.autoscaling.v2beta1.inputs.CrossVersionObjectReferencePatchArgs;
import com.pulumi.kubernetes.meta.v1.inputs.LabelSelectorPatchArgs;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * ObjectMetricSource indicates how to scale on a metric describing a kubernetes object (for example, hits-per-second on an Ingress object).
 * 
 */
public final class ObjectMetricSourcePatchArgs extends com.pulumi.resources.ResourceArgs {

    public static final ObjectMetricSourcePatchArgs Empty = new ObjectMetricSourcePatchArgs();

    /**
     * averageValue is the target value of the average of the metric across all relevant pods (as a quantity)
     * 
     */
    @Import(name="averageValue")
    private @Nullable Output averageValue;

    /**
     * @return averageValue is the target value of the average of the metric across all relevant pods (as a quantity)
     * 
     */
    public Optional> averageValue() {
        return Optional.ofNullable(this.averageValue);
    }

    /**
     * metricName is the name of the metric in question.
     * 
     */
    @Import(name="metricName")
    private @Nullable Output metricName;

    /**
     * @return metricName is the name of the metric in question.
     * 
     */
    public Optional> metricName() {
        return Optional.ofNullable(this.metricName);
    }

    /**
     * selector is the string-encoded form of a standard kubernetes label selector for the given metric When set, it is passed as an additional parameter to the metrics server for more specific metrics scoping When unset, just the metricName will be used to gather metrics.
     * 
     */
    @Import(name="selector")
    private @Nullable Output selector;

    /**
     * @return selector is the string-encoded form of a standard kubernetes label selector for the given metric When set, it is passed as an additional parameter to the metrics server for more specific metrics scoping When unset, just the metricName will be used to gather metrics.
     * 
     */
    public Optional> selector() {
        return Optional.ofNullable(this.selector);
    }

    /**
     * target is the described Kubernetes object.
     * 
     */
    @Import(name="target")
    private @Nullable Output target;

    /**
     * @return target is the described Kubernetes object.
     * 
     */
    public Optional> target() {
        return Optional.ofNullable(this.target);
    }

    /**
     * targetValue is the target value of the metric (as a quantity).
     * 
     */
    @Import(name="targetValue")
    private @Nullable Output targetValue;

    /**
     * @return targetValue is the target value of the metric (as a quantity).
     * 
     */
    public Optional> targetValue() {
        return Optional.ofNullable(this.targetValue);
    }

    private ObjectMetricSourcePatchArgs() {}

    private ObjectMetricSourcePatchArgs(ObjectMetricSourcePatchArgs $) {
        this.averageValue = $.averageValue;
        this.metricName = $.metricName;
        this.selector = $.selector;
        this.target = $.target;
        this.targetValue = $.targetValue;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(ObjectMetricSourcePatchArgs defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private ObjectMetricSourcePatchArgs $;

        public Builder() {
            $ = new ObjectMetricSourcePatchArgs();
        }

        public Builder(ObjectMetricSourcePatchArgs defaults) {
            $ = new ObjectMetricSourcePatchArgs(Objects.requireNonNull(defaults));
        }

        /**
         * @param averageValue averageValue is the target value of the average of the metric across all relevant pods (as a quantity)
         * 
         * @return builder
         * 
         */
        public Builder averageValue(@Nullable Output averageValue) {
            $.averageValue = averageValue;
            return this;
        }

        /**
         * @param averageValue averageValue is the target value of the average of the metric across all relevant pods (as a quantity)
         * 
         * @return builder
         * 
         */
        public Builder averageValue(String averageValue) {
            return averageValue(Output.of(averageValue));
        }

        /**
         * @param metricName metricName is the name of the metric in question.
         * 
         * @return builder
         * 
         */
        public Builder metricName(@Nullable Output metricName) {
            $.metricName = metricName;
            return this;
        }

        /**
         * @param metricName metricName is the name of the metric in question.
         * 
         * @return builder
         * 
         */
        public Builder metricName(String metricName) {
            return metricName(Output.of(metricName));
        }

        /**
         * @param selector selector is the string-encoded form of a standard kubernetes label selector for the given metric When set, it is passed as an additional parameter to the metrics server for more specific metrics scoping When unset, just the metricName will be used to gather metrics.
         * 
         * @return builder
         * 
         */
        public Builder selector(@Nullable Output selector) {
            $.selector = selector;
            return this;
        }

        /**
         * @param selector selector is the string-encoded form of a standard kubernetes label selector for the given metric When set, it is passed as an additional parameter to the metrics server for more specific metrics scoping When unset, just the metricName will be used to gather metrics.
         * 
         * @return builder
         * 
         */
        public Builder selector(LabelSelectorPatchArgs selector) {
            return selector(Output.of(selector));
        }

        /**
         * @param target target is the described Kubernetes object.
         * 
         * @return builder
         * 
         */
        public Builder target(@Nullable Output target) {
            $.target = target;
            return this;
        }

        /**
         * @param target target is the described Kubernetes object.
         * 
         * @return builder
         * 
         */
        public Builder target(CrossVersionObjectReferencePatchArgs target) {
            return target(Output.of(target));
        }

        /**
         * @param targetValue targetValue is the target value of the metric (as a quantity).
         * 
         * @return builder
         * 
         */
        public Builder targetValue(@Nullable Output targetValue) {
            $.targetValue = targetValue;
            return this;
        }

        /**
         * @param targetValue targetValue is the target value of the metric (as a quantity).
         * 
         * @return builder
         * 
         */
        public Builder targetValue(String targetValue) {
            return targetValue(Output.of(targetValue));
        }

        public ObjectMetricSourcePatchArgs build() {
            return $;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy