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

com.pulumi.googlenative.appengine.v1.inputs.AutomaticScalingArgs 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.googlenative.appengine.v1.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.googlenative.appengine.v1.inputs.CpuUtilizationArgs;
import com.pulumi.googlenative.appengine.v1.inputs.DiskUtilizationArgs;
import com.pulumi.googlenative.appengine.v1.inputs.NetworkUtilizationArgs;
import com.pulumi.googlenative.appengine.v1.inputs.RequestUtilizationArgs;
import com.pulumi.googlenative.appengine.v1.inputs.StandardSchedulerSettingsArgs;
import java.lang.Integer;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * Automatic scaling is based on request rate, response latencies, and other application metrics.
 * 
 */
public final class AutomaticScalingArgs extends com.pulumi.resources.ResourceArgs {

    public static final AutomaticScalingArgs Empty = new AutomaticScalingArgs();

    /**
     * The time period that the Autoscaler (https://cloud.google.com/compute/docs/autoscaler/) should wait before it starts collecting information from a new instance. This prevents the autoscaler from collecting information when the instance is initializing, during which the collected usage would not be reliable. Only applicable in the App Engine flexible environment.
     * 
     */
    @Import(name="coolDownPeriod")
    private @Nullable Output coolDownPeriod;

    /**
     * @return The time period that the Autoscaler (https://cloud.google.com/compute/docs/autoscaler/) should wait before it starts collecting information from a new instance. This prevents the autoscaler from collecting information when the instance is initializing, during which the collected usage would not be reliable. Only applicable in the App Engine flexible environment.
     * 
     */
    public Optional> coolDownPeriod() {
        return Optional.ofNullable(this.coolDownPeriod);
    }

    /**
     * Target scaling by CPU usage.
     * 
     */
    @Import(name="cpuUtilization")
    private @Nullable Output cpuUtilization;

    /**
     * @return Target scaling by CPU usage.
     * 
     */
    public Optional> cpuUtilization() {
        return Optional.ofNullable(this.cpuUtilization);
    }

    /**
     * Target scaling by disk usage.
     * 
     */
    @Import(name="diskUtilization")
    private @Nullable Output diskUtilization;

    /**
     * @return Target scaling by disk usage.
     * 
     */
    public Optional> diskUtilization() {
        return Optional.ofNullable(this.diskUtilization);
    }

    /**
     * Number of concurrent requests an automatic scaling instance can accept before the scheduler spawns a new instance.Defaults to a runtime-specific value.
     * 
     */
    @Import(name="maxConcurrentRequests")
    private @Nullable Output maxConcurrentRequests;

    /**
     * @return Number of concurrent requests an automatic scaling instance can accept before the scheduler spawns a new instance.Defaults to a runtime-specific value.
     * 
     */
    public Optional> maxConcurrentRequests() {
        return Optional.ofNullable(this.maxConcurrentRequests);
    }

    /**
     * Maximum number of idle instances that should be maintained for this version.
     * 
     */
    @Import(name="maxIdleInstances")
    private @Nullable Output maxIdleInstances;

    /**
     * @return Maximum number of idle instances that should be maintained for this version.
     * 
     */
    public Optional> maxIdleInstances() {
        return Optional.ofNullable(this.maxIdleInstances);
    }

    /**
     * Maximum amount of time that a request should wait in the pending queue before starting a new instance to handle it.
     * 
     */
    @Import(name="maxPendingLatency")
    private @Nullable Output maxPendingLatency;

    /**
     * @return Maximum amount of time that a request should wait in the pending queue before starting a new instance to handle it.
     * 
     */
    public Optional> maxPendingLatency() {
        return Optional.ofNullable(this.maxPendingLatency);
    }

    /**
     * Maximum number of instances that should be started to handle requests for this version.
     * 
     */
    @Import(name="maxTotalInstances")
    private @Nullable Output maxTotalInstances;

    /**
     * @return Maximum number of instances that should be started to handle requests for this version.
     * 
     */
    public Optional> maxTotalInstances() {
        return Optional.ofNullable(this.maxTotalInstances);
    }

    /**
     * Minimum number of idle instances that should be maintained for this version. Only applicable for the default version of a service.
     * 
     */
    @Import(name="minIdleInstances")
    private @Nullable Output minIdleInstances;

    /**
     * @return Minimum number of idle instances that should be maintained for this version. Only applicable for the default version of a service.
     * 
     */
    public Optional> minIdleInstances() {
        return Optional.ofNullable(this.minIdleInstances);
    }

    /**
     * Minimum amount of time a request should wait in the pending queue before starting a new instance to handle it.
     * 
     */
    @Import(name="minPendingLatency")
    private @Nullable Output minPendingLatency;

    /**
     * @return Minimum amount of time a request should wait in the pending queue before starting a new instance to handle it.
     * 
     */
    public Optional> minPendingLatency() {
        return Optional.ofNullable(this.minPendingLatency);
    }

    /**
     * Minimum number of running instances that should be maintained for this version.
     * 
     */
    @Import(name="minTotalInstances")
    private @Nullable Output minTotalInstances;

    /**
     * @return Minimum number of running instances that should be maintained for this version.
     * 
     */
    public Optional> minTotalInstances() {
        return Optional.ofNullable(this.minTotalInstances);
    }

    /**
     * Target scaling by network usage.
     * 
     */
    @Import(name="networkUtilization")
    private @Nullable Output networkUtilization;

    /**
     * @return Target scaling by network usage.
     * 
     */
    public Optional> networkUtilization() {
        return Optional.ofNullable(this.networkUtilization);
    }

    /**
     * Target scaling by request utilization.
     * 
     */
    @Import(name="requestUtilization")
    private @Nullable Output requestUtilization;

    /**
     * @return Target scaling by request utilization.
     * 
     */
    public Optional> requestUtilization() {
        return Optional.ofNullable(this.requestUtilization);
    }

    /**
     * Scheduler settings for standard environment.
     * 
     */
    @Import(name="standardSchedulerSettings")
    private @Nullable Output standardSchedulerSettings;

    /**
     * @return Scheduler settings for standard environment.
     * 
     */
    public Optional> standardSchedulerSettings() {
        return Optional.ofNullable(this.standardSchedulerSettings);
    }

    private AutomaticScalingArgs() {}

    private AutomaticScalingArgs(AutomaticScalingArgs $) {
        this.coolDownPeriod = $.coolDownPeriod;
        this.cpuUtilization = $.cpuUtilization;
        this.diskUtilization = $.diskUtilization;
        this.maxConcurrentRequests = $.maxConcurrentRequests;
        this.maxIdleInstances = $.maxIdleInstances;
        this.maxPendingLatency = $.maxPendingLatency;
        this.maxTotalInstances = $.maxTotalInstances;
        this.minIdleInstances = $.minIdleInstances;
        this.minPendingLatency = $.minPendingLatency;
        this.minTotalInstances = $.minTotalInstances;
        this.networkUtilization = $.networkUtilization;
        this.requestUtilization = $.requestUtilization;
        this.standardSchedulerSettings = $.standardSchedulerSettings;
    }

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

    public static final class Builder {
        private AutomaticScalingArgs $;

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

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

        /**
         * @param coolDownPeriod The time period that the Autoscaler (https://cloud.google.com/compute/docs/autoscaler/) should wait before it starts collecting information from a new instance. This prevents the autoscaler from collecting information when the instance is initializing, during which the collected usage would not be reliable. Only applicable in the App Engine flexible environment.
         * 
         * @return builder
         * 
         */
        public Builder coolDownPeriod(@Nullable Output coolDownPeriod) {
            $.coolDownPeriod = coolDownPeriod;
            return this;
        }

        /**
         * @param coolDownPeriod The time period that the Autoscaler (https://cloud.google.com/compute/docs/autoscaler/) should wait before it starts collecting information from a new instance. This prevents the autoscaler from collecting information when the instance is initializing, during which the collected usage would not be reliable. Only applicable in the App Engine flexible environment.
         * 
         * @return builder
         * 
         */
        public Builder coolDownPeriod(String coolDownPeriod) {
            return coolDownPeriod(Output.of(coolDownPeriod));
        }

        /**
         * @param cpuUtilization Target scaling by CPU usage.
         * 
         * @return builder
         * 
         */
        public Builder cpuUtilization(@Nullable Output cpuUtilization) {
            $.cpuUtilization = cpuUtilization;
            return this;
        }

        /**
         * @param cpuUtilization Target scaling by CPU usage.
         * 
         * @return builder
         * 
         */
        public Builder cpuUtilization(CpuUtilizationArgs cpuUtilization) {
            return cpuUtilization(Output.of(cpuUtilization));
        }

        /**
         * @param diskUtilization Target scaling by disk usage.
         * 
         * @return builder
         * 
         */
        public Builder diskUtilization(@Nullable Output diskUtilization) {
            $.diskUtilization = diskUtilization;
            return this;
        }

        /**
         * @param diskUtilization Target scaling by disk usage.
         * 
         * @return builder
         * 
         */
        public Builder diskUtilization(DiskUtilizationArgs diskUtilization) {
            return diskUtilization(Output.of(diskUtilization));
        }

        /**
         * @param maxConcurrentRequests Number of concurrent requests an automatic scaling instance can accept before the scheduler spawns a new instance.Defaults to a runtime-specific value.
         * 
         * @return builder
         * 
         */
        public Builder maxConcurrentRequests(@Nullable Output maxConcurrentRequests) {
            $.maxConcurrentRequests = maxConcurrentRequests;
            return this;
        }

        /**
         * @param maxConcurrentRequests Number of concurrent requests an automatic scaling instance can accept before the scheduler spawns a new instance.Defaults to a runtime-specific value.
         * 
         * @return builder
         * 
         */
        public Builder maxConcurrentRequests(Integer maxConcurrentRequests) {
            return maxConcurrentRequests(Output.of(maxConcurrentRequests));
        }

        /**
         * @param maxIdleInstances Maximum number of idle instances that should be maintained for this version.
         * 
         * @return builder
         * 
         */
        public Builder maxIdleInstances(@Nullable Output maxIdleInstances) {
            $.maxIdleInstances = maxIdleInstances;
            return this;
        }

        /**
         * @param maxIdleInstances Maximum number of idle instances that should be maintained for this version.
         * 
         * @return builder
         * 
         */
        public Builder maxIdleInstances(Integer maxIdleInstances) {
            return maxIdleInstances(Output.of(maxIdleInstances));
        }

        /**
         * @param maxPendingLatency Maximum amount of time that a request should wait in the pending queue before starting a new instance to handle it.
         * 
         * @return builder
         * 
         */
        public Builder maxPendingLatency(@Nullable Output maxPendingLatency) {
            $.maxPendingLatency = maxPendingLatency;
            return this;
        }

        /**
         * @param maxPendingLatency Maximum amount of time that a request should wait in the pending queue before starting a new instance to handle it.
         * 
         * @return builder
         * 
         */
        public Builder maxPendingLatency(String maxPendingLatency) {
            return maxPendingLatency(Output.of(maxPendingLatency));
        }

        /**
         * @param maxTotalInstances Maximum number of instances that should be started to handle requests for this version.
         * 
         * @return builder
         * 
         */
        public Builder maxTotalInstances(@Nullable Output maxTotalInstances) {
            $.maxTotalInstances = maxTotalInstances;
            return this;
        }

        /**
         * @param maxTotalInstances Maximum number of instances that should be started to handle requests for this version.
         * 
         * @return builder
         * 
         */
        public Builder maxTotalInstances(Integer maxTotalInstances) {
            return maxTotalInstances(Output.of(maxTotalInstances));
        }

        /**
         * @param minIdleInstances Minimum number of idle instances that should be maintained for this version. Only applicable for the default version of a service.
         * 
         * @return builder
         * 
         */
        public Builder minIdleInstances(@Nullable Output minIdleInstances) {
            $.minIdleInstances = minIdleInstances;
            return this;
        }

        /**
         * @param minIdleInstances Minimum number of idle instances that should be maintained for this version. Only applicable for the default version of a service.
         * 
         * @return builder
         * 
         */
        public Builder minIdleInstances(Integer minIdleInstances) {
            return minIdleInstances(Output.of(minIdleInstances));
        }

        /**
         * @param minPendingLatency Minimum amount of time a request should wait in the pending queue before starting a new instance to handle it.
         * 
         * @return builder
         * 
         */
        public Builder minPendingLatency(@Nullable Output minPendingLatency) {
            $.minPendingLatency = minPendingLatency;
            return this;
        }

        /**
         * @param minPendingLatency Minimum amount of time a request should wait in the pending queue before starting a new instance to handle it.
         * 
         * @return builder
         * 
         */
        public Builder minPendingLatency(String minPendingLatency) {
            return minPendingLatency(Output.of(minPendingLatency));
        }

        /**
         * @param minTotalInstances Minimum number of running instances that should be maintained for this version.
         * 
         * @return builder
         * 
         */
        public Builder minTotalInstances(@Nullable Output minTotalInstances) {
            $.minTotalInstances = minTotalInstances;
            return this;
        }

        /**
         * @param minTotalInstances Minimum number of running instances that should be maintained for this version.
         * 
         * @return builder
         * 
         */
        public Builder minTotalInstances(Integer minTotalInstances) {
            return minTotalInstances(Output.of(minTotalInstances));
        }

        /**
         * @param networkUtilization Target scaling by network usage.
         * 
         * @return builder
         * 
         */
        public Builder networkUtilization(@Nullable Output networkUtilization) {
            $.networkUtilization = networkUtilization;
            return this;
        }

        /**
         * @param networkUtilization Target scaling by network usage.
         * 
         * @return builder
         * 
         */
        public Builder networkUtilization(NetworkUtilizationArgs networkUtilization) {
            return networkUtilization(Output.of(networkUtilization));
        }

        /**
         * @param requestUtilization Target scaling by request utilization.
         * 
         * @return builder
         * 
         */
        public Builder requestUtilization(@Nullable Output requestUtilization) {
            $.requestUtilization = requestUtilization;
            return this;
        }

        /**
         * @param requestUtilization Target scaling by request utilization.
         * 
         * @return builder
         * 
         */
        public Builder requestUtilization(RequestUtilizationArgs requestUtilization) {
            return requestUtilization(Output.of(requestUtilization));
        }

        /**
         * @param standardSchedulerSettings Scheduler settings for standard environment.
         * 
         * @return builder
         * 
         */
        public Builder standardSchedulerSettings(@Nullable Output standardSchedulerSettings) {
            $.standardSchedulerSettings = standardSchedulerSettings;
            return this;
        }

        /**
         * @param standardSchedulerSettings Scheduler settings for standard environment.
         * 
         * @return builder
         * 
         */
        public Builder standardSchedulerSettings(StandardSchedulerSettingsArgs standardSchedulerSettings) {
            return standardSchedulerSettings(Output.of(standardSchedulerSettings));
        }

        public AutomaticScalingArgs build() {
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy