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

com.pulumi.azurenative.alertsmanagement.PrometheusRuleGroupArgs Maven / Gradle / Ivy

There is a newer version: 2.72.0
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.azurenative.alertsmanagement;

import com.pulumi.azurenative.alertsmanagement.inputs.PrometheusRuleArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Boolean;
import java.lang.String;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final PrometheusRuleGroupArgs Empty = new PrometheusRuleGroupArgs();

    /**
     * Apply rule to data from a specific cluster.
     * 
     */
    @Import(name="clusterName")
    private @Nullable Output clusterName;

    /**
     * @return Apply rule to data from a specific cluster.
     * 
     */
    public Optional> clusterName() {
        return Optional.ofNullable(this.clusterName);
    }

    /**
     * Rule group description.
     * 
     */
    @Import(name="description")
    private @Nullable Output description;

    /**
     * @return Rule group description.
     * 
     */
    public Optional> description() {
        return Optional.ofNullable(this.description);
    }

    /**
     * Enable/disable rule group.
     * 
     */
    @Import(name="enabled")
    private @Nullable Output enabled;

    /**
     * @return Enable/disable rule group.
     * 
     */
    public Optional> enabled() {
        return Optional.ofNullable(this.enabled);
    }

    /**
     * The interval in which to run the Prometheus rule group represented in ISO 8601 duration format. Should be between 1 and 15 minutes
     * 
     */
    @Import(name="interval")
    private @Nullable Output interval;

    /**
     * @return The interval in which to run the Prometheus rule group represented in ISO 8601 duration format. Should be between 1 and 15 minutes
     * 
     */
    public Optional> interval() {
        return Optional.ofNullable(this.interval);
    }

    /**
     * The geo-location where the resource lives
     * 
     */
    @Import(name="location")
    private @Nullable Output location;

    /**
     * @return The geo-location where the resource lives
     * 
     */
    public Optional> location() {
        return Optional.ofNullable(this.location);
    }

    /**
     * The name of the resource group. The name is case insensitive.
     * 
     */
    @Import(name="resourceGroupName", required=true)
    private Output resourceGroupName;

    /**
     * @return The name of the resource group. The name is case insensitive.
     * 
     */
    public Output resourceGroupName() {
        return this.resourceGroupName;
    }

    /**
     * The name of the rule group.
     * 
     */
    @Import(name="ruleGroupName")
    private @Nullable Output ruleGroupName;

    /**
     * @return The name of the rule group.
     * 
     */
    public Optional> ruleGroupName() {
        return Optional.ofNullable(this.ruleGroupName);
    }

    /**
     * Defines the rules in the Prometheus rule group.
     * 
     */
    @Import(name="rules", required=true)
    private Output> rules;

    /**
     * @return Defines the rules in the Prometheus rule group.
     * 
     */
    public Output> rules() {
        return this.rules;
    }

    /**
     * Target Azure Monitor workspaces resource ids. This api-version is currently limited to creating with one scope. This may change in future.
     * 
     */
    @Import(name="scopes", required=true)
    private Output> scopes;

    /**
     * @return Target Azure Monitor workspaces resource ids. This api-version is currently limited to creating with one scope. This may change in future.
     * 
     */
    public Output> scopes() {
        return this.scopes;
    }

    /**
     * Resource tags.
     * 
     */
    @Import(name="tags")
    private @Nullable Output> tags;

    /**
     * @return Resource tags.
     * 
     */
    public Optional>> tags() {
        return Optional.ofNullable(this.tags);
    }

    private PrometheusRuleGroupArgs() {}

    private PrometheusRuleGroupArgs(PrometheusRuleGroupArgs $) {
        this.clusterName = $.clusterName;
        this.description = $.description;
        this.enabled = $.enabled;
        this.interval = $.interval;
        this.location = $.location;
        this.resourceGroupName = $.resourceGroupName;
        this.ruleGroupName = $.ruleGroupName;
        this.rules = $.rules;
        this.scopes = $.scopes;
        this.tags = $.tags;
    }

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

    public static final class Builder {
        private PrometheusRuleGroupArgs $;

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

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

        /**
         * @param clusterName Apply rule to data from a specific cluster.
         * 
         * @return builder
         * 
         */
        public Builder clusterName(@Nullable Output clusterName) {
            $.clusterName = clusterName;
            return this;
        }

        /**
         * @param clusterName Apply rule to data from a specific cluster.
         * 
         * @return builder
         * 
         */
        public Builder clusterName(String clusterName) {
            return clusterName(Output.of(clusterName));
        }

        /**
         * @param description Rule group description.
         * 
         * @return builder
         * 
         */
        public Builder description(@Nullable Output description) {
            $.description = description;
            return this;
        }

        /**
         * @param description Rule group description.
         * 
         * @return builder
         * 
         */
        public Builder description(String description) {
            return description(Output.of(description));
        }

        /**
         * @param enabled Enable/disable rule group.
         * 
         * @return builder
         * 
         */
        public Builder enabled(@Nullable Output enabled) {
            $.enabled = enabled;
            return this;
        }

        /**
         * @param enabled Enable/disable rule group.
         * 
         * @return builder
         * 
         */
        public Builder enabled(Boolean enabled) {
            return enabled(Output.of(enabled));
        }

        /**
         * @param interval The interval in which to run the Prometheus rule group represented in ISO 8601 duration format. Should be between 1 and 15 minutes
         * 
         * @return builder
         * 
         */
        public Builder interval(@Nullable Output interval) {
            $.interval = interval;
            return this;
        }

        /**
         * @param interval The interval in which to run the Prometheus rule group represented in ISO 8601 duration format. Should be between 1 and 15 minutes
         * 
         * @return builder
         * 
         */
        public Builder interval(String interval) {
            return interval(Output.of(interval));
        }

        /**
         * @param location The geo-location where the resource lives
         * 
         * @return builder
         * 
         */
        public Builder location(@Nullable Output location) {
            $.location = location;
            return this;
        }

        /**
         * @param location The geo-location where the resource lives
         * 
         * @return builder
         * 
         */
        public Builder location(String location) {
            return location(Output.of(location));
        }

        /**
         * @param resourceGroupName The name of the resource group. The name is case insensitive.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(Output resourceGroupName) {
            $.resourceGroupName = resourceGroupName;
            return this;
        }

        /**
         * @param resourceGroupName The name of the resource group. The name is case insensitive.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(String resourceGroupName) {
            return resourceGroupName(Output.of(resourceGroupName));
        }

        /**
         * @param ruleGroupName The name of the rule group.
         * 
         * @return builder
         * 
         */
        public Builder ruleGroupName(@Nullable Output ruleGroupName) {
            $.ruleGroupName = ruleGroupName;
            return this;
        }

        /**
         * @param ruleGroupName The name of the rule group.
         * 
         * @return builder
         * 
         */
        public Builder ruleGroupName(String ruleGroupName) {
            return ruleGroupName(Output.of(ruleGroupName));
        }

        /**
         * @param rules Defines the rules in the Prometheus rule group.
         * 
         * @return builder
         * 
         */
        public Builder rules(Output> rules) {
            $.rules = rules;
            return this;
        }

        /**
         * @param rules Defines the rules in the Prometheus rule group.
         * 
         * @return builder
         * 
         */
        public Builder rules(List rules) {
            return rules(Output.of(rules));
        }

        /**
         * @param rules Defines the rules in the Prometheus rule group.
         * 
         * @return builder
         * 
         */
        public Builder rules(PrometheusRuleArgs... rules) {
            return rules(List.of(rules));
        }

        /**
         * @param scopes Target Azure Monitor workspaces resource ids. This api-version is currently limited to creating with one scope. This may change in future.
         * 
         * @return builder
         * 
         */
        public Builder scopes(Output> scopes) {
            $.scopes = scopes;
            return this;
        }

        /**
         * @param scopes Target Azure Monitor workspaces resource ids. This api-version is currently limited to creating with one scope. This may change in future.
         * 
         * @return builder
         * 
         */
        public Builder scopes(List scopes) {
            return scopes(Output.of(scopes));
        }

        /**
         * @param scopes Target Azure Monitor workspaces resource ids. This api-version is currently limited to creating with one scope. This may change in future.
         * 
         * @return builder
         * 
         */
        public Builder scopes(String... scopes) {
            return scopes(List.of(scopes));
        }

        /**
         * @param tags Resource tags.
         * 
         * @return builder
         * 
         */
        public Builder tags(@Nullable Output> tags) {
            $.tags = tags;
            return this;
        }

        /**
         * @param tags Resource tags.
         * 
         * @return builder
         * 
         */
        public Builder tags(Map tags) {
            return tags(Output.of(tags));
        }

        public PrometheusRuleGroupArgs build() {
            if ($.resourceGroupName == null) {
                throw new MissingRequiredPropertyException("PrometheusRuleGroupArgs", "resourceGroupName");
            }
            if ($.rules == null) {
                throw new MissingRequiredPropertyException("PrometheusRuleGroupArgs", "rules");
            }
            if ($.scopes == null) {
                throw new MissingRequiredPropertyException("PrometheusRuleGroupArgs", "scopes");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy