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

com.pulumi.alicloud.cms.kotlin.HybridMonitorSlsTaskArgs.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: 3.62.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.alicloud.cms.kotlin

import com.pulumi.alicloud.cms.HybridMonitorSlsTaskArgs.builder
import com.pulumi.alicloud.cms.kotlin.inputs.HybridMonitorSlsTaskAttachLabelArgs
import com.pulumi.alicloud.cms.kotlin.inputs.HybridMonitorSlsTaskAttachLabelArgsBuilder
import com.pulumi.alicloud.cms.kotlin.inputs.HybridMonitorSlsTaskSlsProcessConfigArgs
import com.pulumi.alicloud.cms.kotlin.inputs.HybridMonitorSlsTaskSlsProcessConfigArgsBuilder
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.collections.List
import kotlin.jvm.JvmName

/**
 * Provides a Cloud Monitor Service Hybrid Monitor Sls Task resource.
 * For information about Cloud Monitor Service Hybrid Monitor Sls Task and how to use it, see [What is Hybrid Monitor Sls Task](https://www.alibabacloud.com/help/en/cloudmonitor/latest/createhybridmonitortask).
 * > **NOTE:** Available since v1.179.0.
 * ## Import
 * Cloud Monitor Service Hybrid Monitor Sls Task can be imported using the id, e.g.
 * ```sh
 * $ pulumi import alicloud:cms/hybridMonitorSlsTask:HybridMonitorSlsTask example 
 * ```
 * @property attachLabels The label of the monitoring task. See `attach_labels` below.
 * @property collectInterval The interval at which metrics are collected. Valid values: `15`, `60`(default value). Unit: seconds.
 * @property collectTargetType The type of the collection target, enter the name of the Logstore group.
 * @property description The description of the metric import task.
 * @property namespace The name of the namespace.
 * @property slsProcessConfig The configurations of the logs that are imported from Log Service. See `sls_process_config` below.
 * @property taskName The name of the metric import task, enter the name of the metric for logs imported from Log Service.
 */
public data class HybridMonitorSlsTaskArgs(
    public val attachLabels: Output>? = null,
    public val collectInterval: Output? = null,
    public val collectTargetType: Output? = null,
    public val description: Output? = null,
    public val namespace: Output? = null,
    public val slsProcessConfig: Output? = null,
    public val taskName: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.alicloud.cms.HybridMonitorSlsTaskArgs =
        com.pulumi.alicloud.cms.HybridMonitorSlsTaskArgs.builder()
            .attachLabels(
                attachLabels?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .collectInterval(collectInterval?.applyValue({ args0 -> args0 }))
            .collectTargetType(collectTargetType?.applyValue({ args0 -> args0 }))
            .description(description?.applyValue({ args0 -> args0 }))
            .namespace(namespace?.applyValue({ args0 -> args0 }))
            .slsProcessConfig(slsProcessConfig?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .taskName(taskName?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [HybridMonitorSlsTaskArgs].
 */
@PulumiTagMarker
public class HybridMonitorSlsTaskArgsBuilder internal constructor() {
    private var attachLabels: Output>? = null

    private var collectInterval: Output? = null

    private var collectTargetType: Output? = null

    private var description: Output? = null

    private var namespace: Output? = null

    private var slsProcessConfig: Output? = null

    private var taskName: Output? = null

    /**
     * @param value The label of the monitoring task. See `attach_labels` below.
     */
    @JvmName("qppuuetyvfyepqsn")
    public suspend fun attachLabels(`value`: Output>) {
        this.attachLabels = value
    }

    @JvmName("serpsvelfptwgplm")
    public suspend fun attachLabels(vararg values: Output) {
        this.attachLabels = Output.all(values.asList())
    }

    /**
     * @param values The label of the monitoring task. See `attach_labels` below.
     */
    @JvmName("ylulykxklvukkwtt")
    public suspend fun attachLabels(values: List>) {
        this.attachLabels = Output.all(values)
    }

    /**
     * @param value The interval at which metrics are collected. Valid values: `15`, `60`(default value). Unit: seconds.
     */
    @JvmName("irrvvpgvxhxhvbjk")
    public suspend fun collectInterval(`value`: Output) {
        this.collectInterval = value
    }

    /**
     * @param value The type of the collection target, enter the name of the Logstore group.
     */
    @JvmName("ohwpumpympcskxjw")
    public suspend fun collectTargetType(`value`: Output) {
        this.collectTargetType = value
    }

    /**
     * @param value The description of the metric import task.
     */
    @JvmName("onqsclqknerdlalj")
    public suspend fun description(`value`: Output) {
        this.description = value
    }

    /**
     * @param value The name of the namespace.
     */
    @JvmName("fsucbptikoxleitt")
    public suspend fun namespace(`value`: Output) {
        this.namespace = value
    }

    /**
     * @param value The configurations of the logs that are imported from Log Service. See `sls_process_config` below.
     */
    @JvmName("oklsotmljhwiktiv")
    public suspend fun slsProcessConfig(`value`: Output) {
        this.slsProcessConfig = value
    }

    /**
     * @param value The name of the metric import task, enter the name of the metric for logs imported from Log Service.
     */
    @JvmName("yhcjyfgnwcftwnio")
    public suspend fun taskName(`value`: Output) {
        this.taskName = value
    }

    /**
     * @param value The label of the monitoring task. See `attach_labels` below.
     */
    @JvmName("ruonrrdovvvabcmb")
    public suspend fun attachLabels(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.attachLabels = mapped
    }

    /**
     * @param argument The label of the monitoring task. See `attach_labels` below.
     */
    @JvmName("bixillcwwakfgirg")
    public suspend fun attachLabels(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            HybridMonitorSlsTaskAttachLabelArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.attachLabels = mapped
    }

    /**
     * @param argument The label of the monitoring task. See `attach_labels` below.
     */
    @JvmName("sjquenkqbsndbslv")
    public suspend fun attachLabels(vararg argument: suspend HybridMonitorSlsTaskAttachLabelArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            HybridMonitorSlsTaskAttachLabelArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.attachLabels = mapped
    }

    /**
     * @param argument The label of the monitoring task. See `attach_labels` below.
     */
    @JvmName("utlxobdujenywjxs")
    public suspend fun attachLabels(argument: suspend HybridMonitorSlsTaskAttachLabelArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            HybridMonitorSlsTaskAttachLabelArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.attachLabels = mapped
    }

    /**
     * @param values The label of the monitoring task. See `attach_labels` below.
     */
    @JvmName("gsbyftimkoqwxayf")
    public suspend fun attachLabels(vararg values: HybridMonitorSlsTaskAttachLabelArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.attachLabels = mapped
    }

    /**
     * @param value The interval at which metrics are collected. Valid values: `15`, `60`(default value). Unit: seconds.
     */
    @JvmName("tfkwfjgyiifjpmay")
    public suspend fun collectInterval(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.collectInterval = mapped
    }

    /**
     * @param value The type of the collection target, enter the name of the Logstore group.
     */
    @JvmName("wcbnhmvvhuwxppwq")
    public suspend fun collectTargetType(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.collectTargetType = mapped
    }

    /**
     * @param value The description of the metric import task.
     */
    @JvmName("ckokeacweekaimkd")
    public suspend fun description(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.description = mapped
    }

    /**
     * @param value The name of the namespace.
     */
    @JvmName("ptccnggrynlvobor")
    public suspend fun namespace(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.namespace = mapped
    }

    /**
     * @param value The configurations of the logs that are imported from Log Service. See `sls_process_config` below.
     */
    @JvmName("jtxfbspyauujljpd")
    public suspend fun slsProcessConfig(`value`: HybridMonitorSlsTaskSlsProcessConfigArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.slsProcessConfig = mapped
    }

    /**
     * @param argument The configurations of the logs that are imported from Log Service. See `sls_process_config` below.
     */
    @JvmName("ebltrpirvelnsqot")
    public suspend fun slsProcessConfig(argument: suspend HybridMonitorSlsTaskSlsProcessConfigArgsBuilder.() -> Unit) {
        val toBeMapped = HybridMonitorSlsTaskSlsProcessConfigArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.slsProcessConfig = mapped
    }

    /**
     * @param value The name of the metric import task, enter the name of the metric for logs imported from Log Service.
     */
    @JvmName("fqgduqlhpvxslbui")
    public suspend fun taskName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.taskName = mapped
    }

    internal fun build(): HybridMonitorSlsTaskArgs = HybridMonitorSlsTaskArgs(
        attachLabels = attachLabels,
        collectInterval = collectInterval,
        collectTargetType = collectTargetType,
        description = description,
        namespace = namespace,
        slsProcessConfig = slsProcessConfig,
        taskName = taskName,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy