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

com.pulumi.awsnative.lookoutmetrics.kotlin.AlertArgs.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 0.122.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.awsnative.lookoutmetrics.kotlin

import com.pulumi.awsnative.lookoutmetrics.AlertArgs.builder
import com.pulumi.awsnative.lookoutmetrics.kotlin.inputs.AlertActionArgs
import com.pulumi.awsnative.lookoutmetrics.kotlin.inputs.AlertActionArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName

/**
 * Resource Type definition for AWS::LookoutMetrics::Alert
 * @property action The action to be taken by the alert when an anomaly is detected.
 * @property alertDescription A description for the alert.
 * @property alertName The name of the alert. If not provided, a name is generated automatically.
 * @property alertSensitivityThreshold A number between 0 and 100 (inclusive) that tunes the sensitivity of the alert.
 * @property anomalyDetectorArn The Amazon resource name (ARN) of the Anomaly Detector to alert.
 */
public data class AlertArgs(
    public val action: Output? = null,
    public val alertDescription: Output? = null,
    public val alertName: Output? = null,
    public val alertSensitivityThreshold: Output? = null,
    public val anomalyDetectorArn: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.lookoutmetrics.AlertArgs =
        com.pulumi.awsnative.lookoutmetrics.AlertArgs.builder()
            .action(action?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .alertDescription(alertDescription?.applyValue({ args0 -> args0 }))
            .alertName(alertName?.applyValue({ args0 -> args0 }))
            .alertSensitivityThreshold(alertSensitivityThreshold?.applyValue({ args0 -> args0 }))
            .anomalyDetectorArn(anomalyDetectorArn?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [AlertArgs].
 */
@PulumiTagMarker
public class AlertArgsBuilder internal constructor() {
    private var action: Output? = null

    private var alertDescription: Output? = null

    private var alertName: Output? = null

    private var alertSensitivityThreshold: Output? = null

    private var anomalyDetectorArn: Output? = null

    /**
     * @param value The action to be taken by the alert when an anomaly is detected.
     */
    @JvmName("ywdnffkbtkujlbqc")
    public suspend fun action(`value`: Output) {
        this.action = value
    }

    /**
     * @param value A description for the alert.
     */
    @JvmName("xmdsxwavoatuabjx")
    public suspend fun alertDescription(`value`: Output) {
        this.alertDescription = value
    }

    /**
     * @param value The name of the alert. If not provided, a name is generated automatically.
     */
    @JvmName("ikfitnkqegoavdeq")
    public suspend fun alertName(`value`: Output) {
        this.alertName = value
    }

    /**
     * @param value A number between 0 and 100 (inclusive) that tunes the sensitivity of the alert.
     */
    @JvmName("vvqbdxcokvxjugvx")
    public suspend fun alertSensitivityThreshold(`value`: Output) {
        this.alertSensitivityThreshold = value
    }

    /**
     * @param value The Amazon resource name (ARN) of the Anomaly Detector to alert.
     */
    @JvmName("wtquhukfdkrpmvqj")
    public suspend fun anomalyDetectorArn(`value`: Output) {
        this.anomalyDetectorArn = value
    }

    /**
     * @param value The action to be taken by the alert when an anomaly is detected.
     */
    @JvmName("cebsaieimoxrbqyp")
    public suspend fun action(`value`: AlertActionArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.action = mapped
    }

    /**
     * @param argument The action to be taken by the alert when an anomaly is detected.
     */
    @JvmName("hmolsklkeflbjrtm")
    public suspend fun action(argument: suspend AlertActionArgsBuilder.() -> Unit) {
        val toBeMapped = AlertActionArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.action = mapped
    }

    /**
     * @param value A description for the alert.
     */
    @JvmName("qdcnuouuffkkrchy")
    public suspend fun alertDescription(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.alertDescription = mapped
    }

    /**
     * @param value The name of the alert. If not provided, a name is generated automatically.
     */
    @JvmName("mffrxocqftonhmvv")
    public suspend fun alertName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.alertName = mapped
    }

    /**
     * @param value A number between 0 and 100 (inclusive) that tunes the sensitivity of the alert.
     */
    @JvmName("hryxfibspevvbfpa")
    public suspend fun alertSensitivityThreshold(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.alertSensitivityThreshold = mapped
    }

    /**
     * @param value The Amazon resource name (ARN) of the Anomaly Detector to alert.
     */
    @JvmName("aulbmbdyonqckkkw")
    public suspend fun anomalyDetectorArn(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.anomalyDetectorArn = mapped
    }

    internal fun build(): AlertArgs = AlertArgs(
        action = action,
        alertDescription = alertDescription,
        alertName = alertName,
        alertSensitivityThreshold = alertSensitivityThreshold,
        anomalyDetectorArn = anomalyDetectorArn,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy