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

com.pulumi.azurenative.servicefabric.outputs.ApplicationUpgradePolicyResponse 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.servicefabric.outputs;

import com.pulumi.azurenative.servicefabric.outputs.ApplicationHealthPolicyResponse;
import com.pulumi.azurenative.servicefabric.outputs.RollingUpgradeMonitoringPolicyResponse;
import com.pulumi.core.annotations.CustomType;
import java.lang.Boolean;
import java.lang.Double;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;

@CustomType
public final class ApplicationUpgradePolicyResponse {
    /**
     * @return Defines a health policy used to evaluate the health of an application or one of its children entities.
     * 
     */
    private @Nullable ApplicationHealthPolicyResponse applicationHealthPolicy;
    /**
     * @return If true, then processes are forcefully restarted during upgrade even when the code version has not changed (the upgrade only changes configuration or data).
     * 
     */
    private @Nullable Boolean forceRestart;
    /**
     * @return Duration in seconds, to wait before a stateless instance is closed, to allow the active requests to drain gracefully. This would be effective when the instance is closing during the application/cluster upgrade, only for those instances which have a non-zero delay duration configured in the service description.
     * 
     */
    private @Nullable Double instanceCloseDelayDuration;
    /**
     * @return Determines whether the application should be recreated on update. If value=true, the rest of the upgrade policy parameters are not allowed.
     * 
     */
    private @Nullable Boolean recreateApplication;
    /**
     * @return The policy used for monitoring the application upgrade
     * 
     */
    private @Nullable RollingUpgradeMonitoringPolicyResponse rollingUpgradeMonitoringPolicy;
    /**
     * @return The mode used to monitor health during a rolling upgrade. The values are Monitored, and UnmonitoredAuto.
     * 
     */
    private @Nullable String upgradeMode;
    /**
     * @return The maximum amount of time to block processing of an upgrade domain and prevent loss of availability when there are unexpected issues. When this timeout expires, processing of the upgrade domain will proceed regardless of availability loss issues. The timeout is reset at the start of each upgrade domain. Valid values are between 0 and 42949672925 inclusive. (unsigned 32-bit integer).
     * 
     */
    private @Nullable Double upgradeReplicaSetCheckTimeout;

    private ApplicationUpgradePolicyResponse() {}
    /**
     * @return Defines a health policy used to evaluate the health of an application or one of its children entities.
     * 
     */
    public Optional applicationHealthPolicy() {
        return Optional.ofNullable(this.applicationHealthPolicy);
    }
    /**
     * @return If true, then processes are forcefully restarted during upgrade even when the code version has not changed (the upgrade only changes configuration or data).
     * 
     */
    public Optional forceRestart() {
        return Optional.ofNullable(this.forceRestart);
    }
    /**
     * @return Duration in seconds, to wait before a stateless instance is closed, to allow the active requests to drain gracefully. This would be effective when the instance is closing during the application/cluster upgrade, only for those instances which have a non-zero delay duration configured in the service description.
     * 
     */
    public Optional instanceCloseDelayDuration() {
        return Optional.ofNullable(this.instanceCloseDelayDuration);
    }
    /**
     * @return Determines whether the application should be recreated on update. If value=true, the rest of the upgrade policy parameters are not allowed.
     * 
     */
    public Optional recreateApplication() {
        return Optional.ofNullable(this.recreateApplication);
    }
    /**
     * @return The policy used for monitoring the application upgrade
     * 
     */
    public Optional rollingUpgradeMonitoringPolicy() {
        return Optional.ofNullable(this.rollingUpgradeMonitoringPolicy);
    }
    /**
     * @return The mode used to monitor health during a rolling upgrade. The values are Monitored, and UnmonitoredAuto.
     * 
     */
    public Optional upgradeMode() {
        return Optional.ofNullable(this.upgradeMode);
    }
    /**
     * @return The maximum amount of time to block processing of an upgrade domain and prevent loss of availability when there are unexpected issues. When this timeout expires, processing of the upgrade domain will proceed regardless of availability loss issues. The timeout is reset at the start of each upgrade domain. Valid values are between 0 and 42949672925 inclusive. (unsigned 32-bit integer).
     * 
     */
    public Optional upgradeReplicaSetCheckTimeout() {
        return Optional.ofNullable(this.upgradeReplicaSetCheckTimeout);
    }

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

    public static Builder builder(ApplicationUpgradePolicyResponse defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private @Nullable ApplicationHealthPolicyResponse applicationHealthPolicy;
        private @Nullable Boolean forceRestart;
        private @Nullable Double instanceCloseDelayDuration;
        private @Nullable Boolean recreateApplication;
        private @Nullable RollingUpgradeMonitoringPolicyResponse rollingUpgradeMonitoringPolicy;
        private @Nullable String upgradeMode;
        private @Nullable Double upgradeReplicaSetCheckTimeout;
        public Builder() {}
        public Builder(ApplicationUpgradePolicyResponse defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.applicationHealthPolicy = defaults.applicationHealthPolicy;
    	      this.forceRestart = defaults.forceRestart;
    	      this.instanceCloseDelayDuration = defaults.instanceCloseDelayDuration;
    	      this.recreateApplication = defaults.recreateApplication;
    	      this.rollingUpgradeMonitoringPolicy = defaults.rollingUpgradeMonitoringPolicy;
    	      this.upgradeMode = defaults.upgradeMode;
    	      this.upgradeReplicaSetCheckTimeout = defaults.upgradeReplicaSetCheckTimeout;
        }

        @CustomType.Setter
        public Builder applicationHealthPolicy(@Nullable ApplicationHealthPolicyResponse applicationHealthPolicy) {

            this.applicationHealthPolicy = applicationHealthPolicy;
            return this;
        }
        @CustomType.Setter
        public Builder forceRestart(@Nullable Boolean forceRestart) {

            this.forceRestart = forceRestart;
            return this;
        }
        @CustomType.Setter
        public Builder instanceCloseDelayDuration(@Nullable Double instanceCloseDelayDuration) {

            this.instanceCloseDelayDuration = instanceCloseDelayDuration;
            return this;
        }
        @CustomType.Setter
        public Builder recreateApplication(@Nullable Boolean recreateApplication) {

            this.recreateApplication = recreateApplication;
            return this;
        }
        @CustomType.Setter
        public Builder rollingUpgradeMonitoringPolicy(@Nullable RollingUpgradeMonitoringPolicyResponse rollingUpgradeMonitoringPolicy) {

            this.rollingUpgradeMonitoringPolicy = rollingUpgradeMonitoringPolicy;
            return this;
        }
        @CustomType.Setter
        public Builder upgradeMode(@Nullable String upgradeMode) {

            this.upgradeMode = upgradeMode;
            return this;
        }
        @CustomType.Setter
        public Builder upgradeReplicaSetCheckTimeout(@Nullable Double upgradeReplicaSetCheckTimeout) {

            this.upgradeReplicaSetCheckTimeout = upgradeReplicaSetCheckTimeout;
            return this;
        }
        public ApplicationUpgradePolicyResponse build() {
            final var _resultValue = new ApplicationUpgradePolicyResponse();
            _resultValue.applicationHealthPolicy = applicationHealthPolicy;
            _resultValue.forceRestart = forceRestart;
            _resultValue.instanceCloseDelayDuration = instanceCloseDelayDuration;
            _resultValue.recreateApplication = recreateApplication;
            _resultValue.rollingUpgradeMonitoringPolicy = rollingUpgradeMonitoringPolicy;
            _resultValue.upgradeMode = upgradeMode;
            _resultValue.upgradeReplicaSetCheckTimeout = upgradeReplicaSetCheckTimeout;
            return _resultValue;
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy