
com.pulumi.awsnative.autoscaling.kotlin.inputs.ScalingPolicyTargetTrackingMetricDataQueryArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-aws-native-kotlin Show documentation
Show all versions of pulumi-aws-native-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.awsnative.autoscaling.kotlin.inputs
import com.pulumi.awsnative.autoscaling.inputs.ScalingPolicyTargetTrackingMetricDataQueryArgs.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.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName
/**
*
* @property expression The math expression to perform on the returned data, if this object is performing a math expression. This expression can use the `Id` of the other metrics to refer to those metrics, and can also use the `Id` of other expressions to use the result of those expressions.
* Conditional: Within each `TargetTrackingMetricDataQuery` object, you must specify either `Expression` or `MetricStat` , but not both.
* @property id A short name that identifies the object's results in the response. This name must be unique among all `TargetTrackingMetricDataQuery` objects specified for a single scaling policy. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the mathematical expression. The valid characters are letters, numbers, and underscores. The first character must be a lowercase letter.
* @property label A human-readable label for this metric or expression. This is especially useful if this is a math expression, so that you know what the value represents.
* @property metricStat Information about the metric data to return.
* Conditional: Within each `TargetTrackingMetricDataQuery` object, you must specify either `Expression` or `MetricStat` , but not both.
* @property returnData Indicates whether to return the timestamps and raw data values of this metric.
* If you use any math expressions, specify `true` for this value for only the final math expression that the metric specification is based on. You must specify `false` for `ReturnData` for all the other metrics and expressions used in the metric specification.
* If you are only retrieving metrics and not performing any math expressions, do not specify anything for `ReturnData` . This sets it to its default ( `true` ).
*/
public data class ScalingPolicyTargetTrackingMetricDataQueryArgs(
public val expression: Output? = null,
public val id: Output,
public val label: Output? = null,
public val metricStat: Output? = null,
public val returnData: Output? = null,
) :
ConvertibleToJava {
override fun toJava(): com.pulumi.awsnative.autoscaling.inputs.ScalingPolicyTargetTrackingMetricDataQueryArgs =
com.pulumi.awsnative.autoscaling.inputs.ScalingPolicyTargetTrackingMetricDataQueryArgs.builder()
.expression(expression?.applyValue({ args0 -> args0 }))
.id(id.applyValue({ args0 -> args0 }))
.label(label?.applyValue({ args0 -> args0 }))
.metricStat(metricStat?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.returnData(returnData?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [ScalingPolicyTargetTrackingMetricDataQueryArgs].
*/
@PulumiTagMarker
public class ScalingPolicyTargetTrackingMetricDataQueryArgsBuilder internal constructor() {
private var expression: Output? = null
private var id: Output? = null
private var label: Output? = null
private var metricStat: Output? = null
private var returnData: Output? = null
/**
* @param value The math expression to perform on the returned data, if this object is performing a math expression. This expression can use the `Id` of the other metrics to refer to those metrics, and can also use the `Id` of other expressions to use the result of those expressions.
* Conditional: Within each `TargetTrackingMetricDataQuery` object, you must specify either `Expression` or `MetricStat` , but not both.
*/
@JvmName("fxkcpopnsjqljefq")
public suspend fun expression(`value`: Output) {
this.expression = value
}
/**
* @param value A short name that identifies the object's results in the response. This name must be unique among all `TargetTrackingMetricDataQuery` objects specified for a single scaling policy. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the mathematical expression. The valid characters are letters, numbers, and underscores. The first character must be a lowercase letter.
*/
@JvmName("uxfvknyqsmmetxqf")
public suspend fun id(`value`: Output) {
this.id = value
}
/**
* @param value A human-readable label for this metric or expression. This is especially useful if this is a math expression, so that you know what the value represents.
*/
@JvmName("kcfumdgcwlsirvbs")
public suspend fun label(`value`: Output) {
this.label = value
}
/**
* @param value Information about the metric data to return.
* Conditional: Within each `TargetTrackingMetricDataQuery` object, you must specify either `Expression` or `MetricStat` , but not both.
*/
@JvmName("pcyptkepyefiteha")
public suspend fun metricStat(`value`: Output) {
this.metricStat = value
}
/**
* @param value Indicates whether to return the timestamps and raw data values of this metric.
* If you use any math expressions, specify `true` for this value for only the final math expression that the metric specification is based on. You must specify `false` for `ReturnData` for all the other metrics and expressions used in the metric specification.
* If you are only retrieving metrics and not performing any math expressions, do not specify anything for `ReturnData` . This sets it to its default ( `true` ).
*/
@JvmName("orpadnjocqknvcgq")
public suspend fun returnData(`value`: Output) {
this.returnData = value
}
/**
* @param value The math expression to perform on the returned data, if this object is performing a math expression. This expression can use the `Id` of the other metrics to refer to those metrics, and can also use the `Id` of other expressions to use the result of those expressions.
* Conditional: Within each `TargetTrackingMetricDataQuery` object, you must specify either `Expression` or `MetricStat` , but not both.
*/
@JvmName("vrmaavocamchyuss")
public suspend fun expression(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.expression = mapped
}
/**
* @param value A short name that identifies the object's results in the response. This name must be unique among all `TargetTrackingMetricDataQuery` objects specified for a single scaling policy. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the mathematical expression. The valid characters are letters, numbers, and underscores. The first character must be a lowercase letter.
*/
@JvmName("uewcrurtkxngntwy")
public suspend fun id(`value`: String) {
val toBeMapped = value
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.id = mapped
}
/**
* @param value A human-readable label for this metric or expression. This is especially useful if this is a math expression, so that you know what the value represents.
*/
@JvmName("kvuqxcrjhwrgdjkp")
public suspend fun label(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.label = mapped
}
/**
* @param value Information about the metric data to return.
* Conditional: Within each `TargetTrackingMetricDataQuery` object, you must specify either `Expression` or `MetricStat` , but not both.
*/
@JvmName("fdlsmevqraujcvbe")
public suspend fun metricStat(`value`: ScalingPolicyTargetTrackingMetricStatArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.metricStat = mapped
}
/**
* @param argument Information about the metric data to return.
* Conditional: Within each `TargetTrackingMetricDataQuery` object, you must specify either `Expression` or `MetricStat` , but not both.
*/
@JvmName("kvwhaojcwjniccef")
public suspend fun metricStat(argument: suspend ScalingPolicyTargetTrackingMetricStatArgsBuilder.() -> Unit) {
val toBeMapped = ScalingPolicyTargetTrackingMetricStatArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.metricStat = mapped
}
/**
* @param value Indicates whether to return the timestamps and raw data values of this metric.
* If you use any math expressions, specify `true` for this value for only the final math expression that the metric specification is based on. You must specify `false` for `ReturnData` for all the other metrics and expressions used in the metric specification.
* If you are only retrieving metrics and not performing any math expressions, do not specify anything for `ReturnData` . This sets it to its default ( `true` ).
*/
@JvmName("haelmroorwelxxeh")
public suspend fun returnData(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.returnData = mapped
}
internal fun build(): ScalingPolicyTargetTrackingMetricDataQueryArgs =
ScalingPolicyTargetTrackingMetricDataQueryArgs(
expression = expression,
id = id ?: throw PulumiNullFieldException("id"),
label = label,
metricStat = metricStat,
returnData = returnData,
)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy