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

com.pulumi.kubernetes.autoscaling.v2.inputs.HorizontalPodAutoscalerBehaviorArgs Maven / Gradle / Ivy

There is a newer version: 4.19.0-alpha.1730750641
Show newest version
// *** 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.v2.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.kubernetes.autoscaling.v2.inputs.HPAScalingRulesArgs;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * HorizontalPodAutoscalerBehavior configures the scaling behavior of the target in both Up and Down directions (scaleUp and scaleDown fields respectively).
 * 
 */
public final class HorizontalPodAutoscalerBehaviorArgs extends com.pulumi.resources.ResourceArgs {

    public static final HorizontalPodAutoscalerBehaviorArgs Empty = new HorizontalPodAutoscalerBehaviorArgs();

    /**
     * scaleDown is scaling policy for scaling Down. If not set, the default value is to allow to scale down to minReplicas pods, with a 300 second stabilization window (i.e., the highest recommendation for the last 300sec is used).
     * 
     */
    @Import(name="scaleDown")
    private @Nullable Output scaleDown;

    /**
     * @return scaleDown is scaling policy for scaling Down. If not set, the default value is to allow to scale down to minReplicas pods, with a 300 second stabilization window (i.e., the highest recommendation for the last 300sec is used).
     * 
     */
    public Optional> scaleDown() {
        return Optional.ofNullable(this.scaleDown);
    }

    /**
     * scaleUp is scaling policy for scaling Up. If not set, the default value is the higher of:
     *   * increase no more than 4 pods per 60 seconds
     *   * double the number of pods per 60 seconds
     *     No stabilization is used.
     * 
     */
    @Import(name="scaleUp")
    private @Nullable Output scaleUp;

    /**
     * @return scaleUp is scaling policy for scaling Up. If not set, the default value is the higher of:
     *   * increase no more than 4 pods per 60 seconds
     *   * double the number of pods per 60 seconds
     *     No stabilization is used.
     * 
     */
    public Optional> scaleUp() {
        return Optional.ofNullable(this.scaleUp);
    }

    private HorizontalPodAutoscalerBehaviorArgs() {}

    private HorizontalPodAutoscalerBehaviorArgs(HorizontalPodAutoscalerBehaviorArgs $) {
        this.scaleDown = $.scaleDown;
        this.scaleUp = $.scaleUp;
    }

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

    public static final class Builder {
        private HorizontalPodAutoscalerBehaviorArgs $;

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

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

        /**
         * @param scaleDown scaleDown is scaling policy for scaling Down. If not set, the default value is to allow to scale down to minReplicas pods, with a 300 second stabilization window (i.e., the highest recommendation for the last 300sec is used).
         * 
         * @return builder
         * 
         */
        public Builder scaleDown(@Nullable Output scaleDown) {
            $.scaleDown = scaleDown;
            return this;
        }

        /**
         * @param scaleDown scaleDown is scaling policy for scaling Down. If not set, the default value is to allow to scale down to minReplicas pods, with a 300 second stabilization window (i.e., the highest recommendation for the last 300sec is used).
         * 
         * @return builder
         * 
         */
        public Builder scaleDown(HPAScalingRulesArgs scaleDown) {
            return scaleDown(Output.of(scaleDown));
        }

        /**
         * @param scaleUp scaleUp is scaling policy for scaling Up. If not set, the default value is the higher of:
         *   * increase no more than 4 pods per 60 seconds
         *   * double the number of pods per 60 seconds
         *     No stabilization is used.
         * 
         * @return builder
         * 
         */
        public Builder scaleUp(@Nullable Output scaleUp) {
            $.scaleUp = scaleUp;
            return this;
        }

        /**
         * @param scaleUp scaleUp is scaling policy for scaling Up. If not set, the default value is the higher of:
         *   * increase no more than 4 pods per 60 seconds
         *   * double the number of pods per 60 seconds
         *     No stabilization is used.
         * 
         * @return builder
         * 
         */
        public Builder scaleUp(HPAScalingRulesArgs scaleUp) {
            return scaleUp(Output.of(scaleUp));
        }

        public HorizontalPodAutoscalerBehaviorArgs build() {
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy