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

com.pulumi.azurenative.appplatform.inputs.DeploymentSettingsArgs 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.azurenative.appplatform.inputs;

import com.pulumi.azurenative.appplatform.inputs.ApmReferenceArgs;
import com.pulumi.azurenative.appplatform.inputs.ContainerProbeSettingsArgs;
import com.pulumi.azurenative.appplatform.inputs.ProbeArgs;
import com.pulumi.azurenative.appplatform.inputs.ResourceRequestsArgs;
import com.pulumi.azurenative.appplatform.inputs.ScaleArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.core.internal.Codegen;
import java.lang.Integer;
import java.lang.Object;
import java.lang.String;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * Deployment settings payload
 * 
 */
public final class DeploymentSettingsArgs extends com.pulumi.resources.ResourceArgs {

    public static final DeploymentSettingsArgs Empty = new DeploymentSettingsArgs();

    /**
     * Collection of addons
     * 
     */
    @Import(name="addonConfigs")
    private @Nullable Output> addonConfigs;

    /**
     * @return Collection of addons
     * 
     */
    public Optional>> addonConfigs() {
        return Optional.ofNullable(this.addonConfigs);
    }

    /**
     * Collection of ApmReferences
     * 
     */
    @Import(name="apms")
    private @Nullable Output> apms;

    /**
     * @return Collection of ApmReferences
     * 
     */
    public Optional>> apms() {
        return Optional.ofNullable(this.apms);
    }

    /**
     * Container liveness and readiness probe settings
     * 
     */
    @Import(name="containerProbeSettings")
    private @Nullable Output containerProbeSettings;

    /**
     * @return Container liveness and readiness probe settings
     * 
     */
    public Optional> containerProbeSettings() {
        return Optional.ofNullable(this.containerProbeSettings);
    }

    /**
     * Collection of environment variables
     * 
     */
    @Import(name="environmentVariables")
    private @Nullable Output> environmentVariables;

    /**
     * @return Collection of environment variables
     * 
     */
    public Optional>> environmentVariables() {
        return Optional.ofNullable(this.environmentVariables);
    }

    /**
     * Periodic probe of App Instance liveness. App Instance will be restarted if the probe fails. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
     * 
     */
    @Import(name="livenessProbe")
    private @Nullable Output livenessProbe;

    /**
     * @return Periodic probe of App Instance liveness. App Instance will be restarted if the probe fails. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
     * 
     */
    public Optional> livenessProbe() {
        return Optional.ofNullable(this.livenessProbe);
    }

    /**
     * Periodic probe of App Instance service readiness. App Instance will be removed from service endpoints if the probe fails. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
     * 
     */
    @Import(name="readinessProbe")
    private @Nullable Output readinessProbe;

    /**
     * @return Periodic probe of App Instance service readiness. App Instance will be removed from service endpoints if the probe fails. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
     * 
     */
    public Optional> readinessProbe() {
        return Optional.ofNullable(this.readinessProbe);
    }

    /**
     * The requested resource quantity for required CPU and Memory. It is recommended that using this field to represent the required CPU and Memory, the old field cpu and memoryInGB will be deprecated later.
     * 
     */
    @Import(name="resourceRequests")
    private @Nullable Output resourceRequests;

    /**
     * @return The requested resource quantity for required CPU and Memory. It is recommended that using this field to represent the required CPU and Memory, the old field cpu and memoryInGB will be deprecated later.
     * 
     */
    public Optional> resourceRequests() {
        return Optional.ofNullable(this.resourceRequests);
    }

    /**
     * Scaling properties for the Azure Spring Apps App Instance.
     * 
     */
    @Import(name="scale")
    private @Nullable Output scale;

    /**
     * @return Scaling properties for the Azure Spring Apps App Instance.
     * 
     */
    public Optional> scale() {
        return Optional.ofNullable(this.scale);
    }

    /**
     * StartupProbe indicates that the App Instance has successfully initialized. If specified, no other probes are executed until this completes successfully. If this probe fails, the Pod will be restarted, just as if the livenessProbe failed. This can be used to provide different probe parameters at the beginning of a App Instance's lifecycle, when it might take a long time to load data or warm a cache, than during steady-state operation. This cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
     * 
     */
    @Import(name="startupProbe")
    private @Nullable Output startupProbe;

    /**
     * @return StartupProbe indicates that the App Instance has successfully initialized. If specified, no other probes are executed until this completes successfully. If this probe fails, the Pod will be restarted, just as if the livenessProbe failed. This can be used to provide different probe parameters at the beginning of a App Instance's lifecycle, when it might take a long time to load data or warm a cache, than during steady-state operation. This cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
     * 
     */
    public Optional> startupProbe() {
        return Optional.ofNullable(this.startupProbe);
    }

    /**
     * Optional duration in seconds the App Instance needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the App Instance are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 90 seconds.
     * 
     */
    @Import(name="terminationGracePeriodSeconds")
    private @Nullable Output terminationGracePeriodSeconds;

    /**
     * @return Optional duration in seconds the App Instance needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the App Instance are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 90 seconds.
     * 
     */
    public Optional> terminationGracePeriodSeconds() {
        return Optional.ofNullable(this.terminationGracePeriodSeconds);
    }

    private DeploymentSettingsArgs() {}

    private DeploymentSettingsArgs(DeploymentSettingsArgs $) {
        this.addonConfigs = $.addonConfigs;
        this.apms = $.apms;
        this.containerProbeSettings = $.containerProbeSettings;
        this.environmentVariables = $.environmentVariables;
        this.livenessProbe = $.livenessProbe;
        this.readinessProbe = $.readinessProbe;
        this.resourceRequests = $.resourceRequests;
        this.scale = $.scale;
        this.startupProbe = $.startupProbe;
        this.terminationGracePeriodSeconds = $.terminationGracePeriodSeconds;
    }

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

    public static final class Builder {
        private DeploymentSettingsArgs $;

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

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

        /**
         * @param addonConfigs Collection of addons
         * 
         * @return builder
         * 
         */
        public Builder addonConfigs(@Nullable Output> addonConfigs) {
            $.addonConfigs = addonConfigs;
            return this;
        }

        /**
         * @param addonConfigs Collection of addons
         * 
         * @return builder
         * 
         */
        public Builder addonConfigs(Map addonConfigs) {
            return addonConfigs(Output.of(addonConfigs));
        }

        /**
         * @param apms Collection of ApmReferences
         * 
         * @return builder
         * 
         */
        public Builder apms(@Nullable Output> apms) {
            $.apms = apms;
            return this;
        }

        /**
         * @param apms Collection of ApmReferences
         * 
         * @return builder
         * 
         */
        public Builder apms(List apms) {
            return apms(Output.of(apms));
        }

        /**
         * @param apms Collection of ApmReferences
         * 
         * @return builder
         * 
         */
        public Builder apms(ApmReferenceArgs... apms) {
            return apms(List.of(apms));
        }

        /**
         * @param containerProbeSettings Container liveness and readiness probe settings
         * 
         * @return builder
         * 
         */
        public Builder containerProbeSettings(@Nullable Output containerProbeSettings) {
            $.containerProbeSettings = containerProbeSettings;
            return this;
        }

        /**
         * @param containerProbeSettings Container liveness and readiness probe settings
         * 
         * @return builder
         * 
         */
        public Builder containerProbeSettings(ContainerProbeSettingsArgs containerProbeSettings) {
            return containerProbeSettings(Output.of(containerProbeSettings));
        }

        /**
         * @param environmentVariables Collection of environment variables
         * 
         * @return builder
         * 
         */
        public Builder environmentVariables(@Nullable Output> environmentVariables) {
            $.environmentVariables = environmentVariables;
            return this;
        }

        /**
         * @param environmentVariables Collection of environment variables
         * 
         * @return builder
         * 
         */
        public Builder environmentVariables(Map environmentVariables) {
            return environmentVariables(Output.of(environmentVariables));
        }

        /**
         * @param livenessProbe Periodic probe of App Instance liveness. App Instance will be restarted if the probe fails. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
         * 
         * @return builder
         * 
         */
        public Builder livenessProbe(@Nullable Output livenessProbe) {
            $.livenessProbe = livenessProbe;
            return this;
        }

        /**
         * @param livenessProbe Periodic probe of App Instance liveness. App Instance will be restarted if the probe fails. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
         * 
         * @return builder
         * 
         */
        public Builder livenessProbe(ProbeArgs livenessProbe) {
            return livenessProbe(Output.of(livenessProbe));
        }

        /**
         * @param readinessProbe Periodic probe of App Instance service readiness. App Instance will be removed from service endpoints if the probe fails. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
         * 
         * @return builder
         * 
         */
        public Builder readinessProbe(@Nullable Output readinessProbe) {
            $.readinessProbe = readinessProbe;
            return this;
        }

        /**
         * @param readinessProbe Periodic probe of App Instance service readiness. App Instance will be removed from service endpoints if the probe fails. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
         * 
         * @return builder
         * 
         */
        public Builder readinessProbe(ProbeArgs readinessProbe) {
            return readinessProbe(Output.of(readinessProbe));
        }

        /**
         * @param resourceRequests The requested resource quantity for required CPU and Memory. It is recommended that using this field to represent the required CPU and Memory, the old field cpu and memoryInGB will be deprecated later.
         * 
         * @return builder
         * 
         */
        public Builder resourceRequests(@Nullable Output resourceRequests) {
            $.resourceRequests = resourceRequests;
            return this;
        }

        /**
         * @param resourceRequests The requested resource quantity for required CPU and Memory. It is recommended that using this field to represent the required CPU and Memory, the old field cpu and memoryInGB will be deprecated later.
         * 
         * @return builder
         * 
         */
        public Builder resourceRequests(ResourceRequestsArgs resourceRequests) {
            return resourceRequests(Output.of(resourceRequests));
        }

        /**
         * @param scale Scaling properties for the Azure Spring Apps App Instance.
         * 
         * @return builder
         * 
         */
        public Builder scale(@Nullable Output scale) {
            $.scale = scale;
            return this;
        }

        /**
         * @param scale Scaling properties for the Azure Spring Apps App Instance.
         * 
         * @return builder
         * 
         */
        public Builder scale(ScaleArgs scale) {
            return scale(Output.of(scale));
        }

        /**
         * @param startupProbe StartupProbe indicates that the App Instance has successfully initialized. If specified, no other probes are executed until this completes successfully. If this probe fails, the Pod will be restarted, just as if the livenessProbe failed. This can be used to provide different probe parameters at the beginning of a App Instance's lifecycle, when it might take a long time to load data or warm a cache, than during steady-state operation. This cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
         * 
         * @return builder
         * 
         */
        public Builder startupProbe(@Nullable Output startupProbe) {
            $.startupProbe = startupProbe;
            return this;
        }

        /**
         * @param startupProbe StartupProbe indicates that the App Instance has successfully initialized. If specified, no other probes are executed until this completes successfully. If this probe fails, the Pod will be restarted, just as if the livenessProbe failed. This can be used to provide different probe parameters at the beginning of a App Instance's lifecycle, when it might take a long time to load data or warm a cache, than during steady-state operation. This cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
         * 
         * @return builder
         * 
         */
        public Builder startupProbe(ProbeArgs startupProbe) {
            return startupProbe(Output.of(startupProbe));
        }

        /**
         * @param terminationGracePeriodSeconds Optional duration in seconds the App Instance needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the App Instance are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 90 seconds.
         * 
         * @return builder
         * 
         */
        public Builder terminationGracePeriodSeconds(@Nullable Output terminationGracePeriodSeconds) {
            $.terminationGracePeriodSeconds = terminationGracePeriodSeconds;
            return this;
        }

        /**
         * @param terminationGracePeriodSeconds Optional duration in seconds the App Instance needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the App Instance are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 90 seconds.
         * 
         * @return builder
         * 
         */
        public Builder terminationGracePeriodSeconds(Integer terminationGracePeriodSeconds) {
            return terminationGracePeriodSeconds(Output.of(terminationGracePeriodSeconds));
        }

        public DeploymentSettingsArgs build() {
            $.terminationGracePeriodSeconds = Codegen.integerProp("terminationGracePeriodSeconds").output().arg($.terminationGracePeriodSeconds).def(90).getNullable();
            return $;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy