![JAR search and dependency download from the Maven repository](/logo.png)
com.pulumi.awsnative.autoscaling.kotlin.inputs.ScalingPolicyMetricStatArgs.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.awsnative.autoscaling.kotlin.inputs
import com.pulumi.awsnative.autoscaling.inputs.ScalingPolicyMetricStatArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName
/**
*
* @property metric The CloudWatch metric to return, including the metric name, namespace, and dimensions. To get the exact metric name, namespace, and dimensions, inspect the [Metric](https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_Metric.html) object that is returned by a call to [ListMetrics](https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_ListMetrics.html) .
* @property stat The statistic to return. It can include any CloudWatch statistic or extended statistic. For a list of valid values, see the table in [Statistics](https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/cloudwatch_concepts.html#Statistic) in the *Amazon CloudWatch User Guide* .
* The most commonly used metrics for predictive scaling are `Average` and `Sum` .
* @property unit The unit to use for the returned data points. For a complete list of the units that CloudWatch supports, see the [MetricDatum](https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_MetricDatum.html) data type in the *Amazon CloudWatch API Reference* .
*/
public data class ScalingPolicyMetricStatArgs(
public val metric: Output,
public val stat: Output,
public val unit: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.awsnative.autoscaling.inputs.ScalingPolicyMetricStatArgs =
com.pulumi.awsnative.autoscaling.inputs.ScalingPolicyMetricStatArgs.builder()
.metric(metric.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.stat(stat.applyValue({ args0 -> args0 }))
.unit(unit?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [ScalingPolicyMetricStatArgs].
*/
@PulumiTagMarker
public class ScalingPolicyMetricStatArgsBuilder internal constructor() {
private var metric: Output? = null
private var stat: Output? = null
private var unit: Output? = null
/**
* @param value The CloudWatch metric to return, including the metric name, namespace, and dimensions. To get the exact metric name, namespace, and dimensions, inspect the [Metric](https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_Metric.html) object that is returned by a call to [ListMetrics](https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_ListMetrics.html) .
*/
@JvmName("yghctkxuantyicaq")
public suspend fun metric(`value`: Output) {
this.metric = value
}
/**
* @param value The statistic to return. It can include any CloudWatch statistic or extended statistic. For a list of valid values, see the table in [Statistics](https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/cloudwatch_concepts.html#Statistic) in the *Amazon CloudWatch User Guide* .
* The most commonly used metrics for predictive scaling are `Average` and `Sum` .
*/
@JvmName("muiutiqiegcjymay")
public suspend fun stat(`value`: Output) {
this.stat = value
}
/**
* @param value The unit to use for the returned data points. For a complete list of the units that CloudWatch supports, see the [MetricDatum](https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_MetricDatum.html) data type in the *Amazon CloudWatch API Reference* .
*/
@JvmName("vjucagyuqgbwystk")
public suspend fun unit(`value`: Output) {
this.unit = value
}
/**
* @param value The CloudWatch metric to return, including the metric name, namespace, and dimensions. To get the exact metric name, namespace, and dimensions, inspect the [Metric](https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_Metric.html) object that is returned by a call to [ListMetrics](https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_ListMetrics.html) .
*/
@JvmName("hsbfoimlulyemelo")
public suspend fun metric(`value`: ScalingPolicyMetricArgs) {
val toBeMapped = value
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.metric = mapped
}
/**
* @param argument The CloudWatch metric to return, including the metric name, namespace, and dimensions. To get the exact metric name, namespace, and dimensions, inspect the [Metric](https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_Metric.html) object that is returned by a call to [ListMetrics](https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_ListMetrics.html) .
*/
@JvmName("mgkyqhuefccmjlxt")
public suspend fun metric(argument: suspend ScalingPolicyMetricArgsBuilder.() -> Unit) {
val toBeMapped = ScalingPolicyMetricArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.metric = mapped
}
/**
* @param value The statistic to return. It can include any CloudWatch statistic or extended statistic. For a list of valid values, see the table in [Statistics](https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/cloudwatch_concepts.html#Statistic) in the *Amazon CloudWatch User Guide* .
* The most commonly used metrics for predictive scaling are `Average` and `Sum` .
*/
@JvmName("ndnsqimhqjaslipv")
public suspend fun stat(`value`: String) {
val toBeMapped = value
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.stat = mapped
}
/**
* @param value The unit to use for the returned data points. For a complete list of the units that CloudWatch supports, see the [MetricDatum](https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_MetricDatum.html) data type in the *Amazon CloudWatch API Reference* .
*/
@JvmName("ubfrolwfunlmrsje")
public suspend fun unit(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.unit = mapped
}
internal fun build(): ScalingPolicyMetricStatArgs = ScalingPolicyMetricStatArgs(
metric = metric ?: throw PulumiNullFieldException("metric"),
stat = stat ?: throw PulumiNullFieldException("stat"),
unit = unit,
)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy