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

com.pulumi.azure.core.inputs.ResourcePolicyRemediationState 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.azure.core.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.Double;
import java.lang.Integer;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class ResourcePolicyRemediationState extends com.pulumi.resources.ResourceArgs {

    public static final ResourcePolicyRemediationState Empty = new ResourcePolicyRemediationState();

    /**
     * A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
     * 
     */
    @Import(name="failurePercentage")
    private @Nullable Output failurePercentage;

    /**
     * @return A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
     * 
     */
    public Optional> failurePercentage() {
        return Optional.ofNullable(this.failurePercentage);
    }

    /**
     * A list of the resource locations that will be remediated.
     * 
     */
    @Import(name="locationFilters")
    private @Nullable Output> locationFilters;

    /**
     * @return A list of the resource locations that will be remediated.
     * 
     */
    public Optional>> locationFilters() {
        return Optional.ofNullable(this.locationFilters);
    }

    /**
     * The name of the Policy Remediation. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="name")
    private @Nullable Output name;

    /**
     * @return The name of the Policy Remediation. Changing this forces a new resource to be created.
     * 
     */
    public Optional> name() {
        return Optional.ofNullable(this.name);
    }

    /**
     * Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
     * 
     */
    @Import(name="parallelDeployments")
    private @Nullable Output parallelDeployments;

    /**
     * @return Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
     * 
     */
    public Optional> parallelDeployments() {
        return Optional.ofNullable(this.parallelDeployments);
    }

    /**
     * The ID of the Policy Assignment that should be remediated.
     * 
     */
    @Import(name="policyAssignmentId")
    private @Nullable Output policyAssignmentId;

    /**
     * @return The ID of the Policy Assignment that should be remediated.
     * 
     */
    public Optional> policyAssignmentId() {
        return Optional.ofNullable(this.policyAssignmentId);
    }

    /**
     * The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
     * 
     */
    @Import(name="policyDefinitionReferenceId")
    private @Nullable Output policyDefinitionReferenceId;

    /**
     * @return The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
     * 
     */
    public Optional> policyDefinitionReferenceId() {
        return Optional.ofNullable(this.policyDefinitionReferenceId);
    }

    /**
     * Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
     * 
     */
    @Import(name="resourceCount")
    private @Nullable Output resourceCount;

    /**
     * @return Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
     * 
     */
    public Optional> resourceCount() {
        return Optional.ofNullable(this.resourceCount);
    }

    /**
     * The way that resources to remediate are discovered. Possible values are `ExistingNonCompliant`, `ReEvaluateCompliance`. Defaults to `ExistingNonCompliant`.
     * 
     */
    @Import(name="resourceDiscoveryMode")
    private @Nullable Output resourceDiscoveryMode;

    /**
     * @return The way that resources to remediate are discovered. Possible values are `ExistingNonCompliant`, `ReEvaluateCompliance`. Defaults to `ExistingNonCompliant`.
     * 
     */
    public Optional> resourceDiscoveryMode() {
        return Optional.ofNullable(this.resourceDiscoveryMode);
    }

    /**
     * The Resource ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="resourceId")
    private @Nullable Output resourceId;

    /**
     * @return The Resource ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
     * 
     */
    public Optional> resourceId() {
        return Optional.ofNullable(this.resourceId);
    }

    private ResourcePolicyRemediationState() {}

    private ResourcePolicyRemediationState(ResourcePolicyRemediationState $) {
        this.failurePercentage = $.failurePercentage;
        this.locationFilters = $.locationFilters;
        this.name = $.name;
        this.parallelDeployments = $.parallelDeployments;
        this.policyAssignmentId = $.policyAssignmentId;
        this.policyDefinitionReferenceId = $.policyDefinitionReferenceId;
        this.resourceCount = $.resourceCount;
        this.resourceDiscoveryMode = $.resourceDiscoveryMode;
        this.resourceId = $.resourceId;
    }

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

    public static final class Builder {
        private ResourcePolicyRemediationState $;

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

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

        /**
         * @param failurePercentage A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
         * 
         * @return builder
         * 
         */
        public Builder failurePercentage(@Nullable Output failurePercentage) {
            $.failurePercentage = failurePercentage;
            return this;
        }

        /**
         * @param failurePercentage A number between 0.0 to 1.0 representing the percentage failure threshold. The remediation will fail if the percentage of failed remediation operations (i.e. failed deployments) exceeds this threshold.
         * 
         * @return builder
         * 
         */
        public Builder failurePercentage(Double failurePercentage) {
            return failurePercentage(Output.of(failurePercentage));
        }

        /**
         * @param locationFilters A list of the resource locations that will be remediated.
         * 
         * @return builder
         * 
         */
        public Builder locationFilters(@Nullable Output> locationFilters) {
            $.locationFilters = locationFilters;
            return this;
        }

        /**
         * @param locationFilters A list of the resource locations that will be remediated.
         * 
         * @return builder
         * 
         */
        public Builder locationFilters(List locationFilters) {
            return locationFilters(Output.of(locationFilters));
        }

        /**
         * @param locationFilters A list of the resource locations that will be remediated.
         * 
         * @return builder
         * 
         */
        public Builder locationFilters(String... locationFilters) {
            return locationFilters(List.of(locationFilters));
        }

        /**
         * @param name The name of the Policy Remediation. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder name(@Nullable Output name) {
            $.name = name;
            return this;
        }

        /**
         * @param name The name of the Policy Remediation. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder name(String name) {
            return name(Output.of(name));
        }

        /**
         * @param parallelDeployments Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
         * 
         * @return builder
         * 
         */
        public Builder parallelDeployments(@Nullable Output parallelDeployments) {
            $.parallelDeployments = parallelDeployments;
            return this;
        }

        /**
         * @param parallelDeployments Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. If not provided, the default parallel deployments value is used.
         * 
         * @return builder
         * 
         */
        public Builder parallelDeployments(Integer parallelDeployments) {
            return parallelDeployments(Output.of(parallelDeployments));
        }

        /**
         * @param policyAssignmentId The ID of the Policy Assignment that should be remediated.
         * 
         * @return builder
         * 
         */
        public Builder policyAssignmentId(@Nullable Output policyAssignmentId) {
            $.policyAssignmentId = policyAssignmentId;
            return this;
        }

        /**
         * @param policyAssignmentId The ID of the Policy Assignment that should be remediated.
         * 
         * @return builder
         * 
         */
        public Builder policyAssignmentId(String policyAssignmentId) {
            return policyAssignmentId(Output.of(policyAssignmentId));
        }

        /**
         * @param policyDefinitionReferenceId The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
         * 
         * @return builder
         * 
         */
        public Builder policyDefinitionReferenceId(@Nullable Output policyDefinitionReferenceId) {
            $.policyDefinitionReferenceId = policyDefinitionReferenceId;
            return this;
        }

        /**
         * @param policyDefinitionReferenceId The unique ID for the policy definition reference within the policy set definition that should be remediated. Required when the policy assignment being remediated assigns a policy set definition.
         * 
         * @return builder
         * 
         */
        public Builder policyDefinitionReferenceId(String policyDefinitionReferenceId) {
            return policyDefinitionReferenceId(Output.of(policyDefinitionReferenceId));
        }

        /**
         * @param resourceCount Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
         * 
         * @return builder
         * 
         */
        public Builder resourceCount(@Nullable Output resourceCount) {
            $.resourceCount = resourceCount;
            return this;
        }

        /**
         * @param resourceCount Determines the max number of resources that can be remediated by the remediation job. If not provided, the default resource count is used.
         * 
         * @return builder
         * 
         */
        public Builder resourceCount(Integer resourceCount) {
            return resourceCount(Output.of(resourceCount));
        }

        /**
         * @param resourceDiscoveryMode The way that resources to remediate are discovered. Possible values are `ExistingNonCompliant`, `ReEvaluateCompliance`. Defaults to `ExistingNonCompliant`.
         * 
         * @return builder
         * 
         */
        public Builder resourceDiscoveryMode(@Nullable Output resourceDiscoveryMode) {
            $.resourceDiscoveryMode = resourceDiscoveryMode;
            return this;
        }

        /**
         * @param resourceDiscoveryMode The way that resources to remediate are discovered. Possible values are `ExistingNonCompliant`, `ReEvaluateCompliance`. Defaults to `ExistingNonCompliant`.
         * 
         * @return builder
         * 
         */
        public Builder resourceDiscoveryMode(String resourceDiscoveryMode) {
            return resourceDiscoveryMode(Output.of(resourceDiscoveryMode));
        }

        /**
         * @param resourceId The Resource ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder resourceId(@Nullable Output resourceId) {
            $.resourceId = resourceId;
            return this;
        }

        /**
         * @param resourceId The Resource ID at which the Policy Remediation should be applied. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder resourceId(String resourceId) {
            return resourceId(Output.of(resourceId));
        }

        public ResourcePolicyRemediationState build() {
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy