com.pulumi.azure.monitoring.kotlin.outputs.DiagnosticSettingMetric.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-azure-kotlin Show documentation
Show all versions of pulumi-azure-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.azure.monitoring.kotlin.outputs
import kotlin.Boolean
import kotlin.Deprecated
import kotlin.String
import kotlin.Suppress
/**
*
* @property category The name of a Diagnostic Metric Category for this Resource.
* > **NOTE:** The Metric Categories available vary depending on the Resource being used. You may wish to use the `azure.monitoring.getDiagnosticCategories` Data Source to identify which categories are available for a given Resource.
* @property enabled Is this Diagnostic Metric enabled? Defaults to `true`.
* @property retentionPolicy A `retention_policy` block as defined below.
* !> **NOTE:** `retention_policy` has been deprecated in favor of `azure.storage.ManagementPolicy` resource - to learn more information on the deprecation [in the Azure documentation](https://aka.ms/diagnostic_settings_log_retention).
*/
public data class DiagnosticSettingMetric(
public val category: String,
public val enabled: Boolean? = null,
@Deprecated(
message = """
`retention_policy` has been deprecated in favor of `azure.storage.ManagementPolicy` resource - to
learn more https://aka.ms/diagnostic_settings_log_retention
""",
)
public val retentionPolicy: DiagnosticSettingMetricRetentionPolicy? = null,
) {
public companion object {
public fun toKotlin(javaType: com.pulumi.azure.monitoring.outputs.DiagnosticSettingMetric):
DiagnosticSettingMetric = DiagnosticSettingMetric(
category = javaType.category(),
enabled = javaType.enabled().map({ args0 -> args0 }).orElse(null),
retentionPolicy = javaType.retentionPolicy().map({ args0 ->
args0.let({ args0 ->
com.pulumi.azure.monitoring.kotlin.outputs.DiagnosticSettingMetricRetentionPolicy.Companion.toKotlin(args0)
})
}).orElse(null),
)
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy