com.pulumi.gcp.compute.kotlin.inputs.AutoscalerAutoscalingPolicyScaleDownControlArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-gcp-kotlin Show documentation
Show all versions of pulumi-gcp-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.gcp.compute.kotlin.inputs
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.compute.inputs.AutoscalerAutoscalingPolicyScaleDownControlArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Int
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName
/**
*
* @property maxScaledDownReplicas A nested object resource
* Structure is documented below.
* @property timeWindowSec How long back autoscaling should look when computing recommendations
* to include directives regarding slower scale down, as described above.
*/
public data class AutoscalerAutoscalingPolicyScaleDownControlArgs(
public val maxScaledDownReplicas: Output? = null,
public val timeWindowSec: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.gcp.compute.inputs.AutoscalerAutoscalingPolicyScaleDownControlArgs =
com.pulumi.gcp.compute.inputs.AutoscalerAutoscalingPolicyScaleDownControlArgs.builder()
.maxScaledDownReplicas(
maxScaledDownReplicas?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.timeWindowSec(timeWindowSec?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [AutoscalerAutoscalingPolicyScaleDownControlArgs].
*/
@PulumiTagMarker
public class AutoscalerAutoscalingPolicyScaleDownControlArgsBuilder internal constructor() {
private var maxScaledDownReplicas:
Output? = null
private var timeWindowSec: Output? = null
/**
* @param value A nested object resource
* Structure is documented below.
*/
@JvmName("ktwslpeeetuslqqn")
public suspend fun maxScaledDownReplicas(`value`: Output) {
this.maxScaledDownReplicas = value
}
/**
* @param value How long back autoscaling should look when computing recommendations
* to include directives regarding slower scale down, as described above.
*/
@JvmName("fnsgxqpyosujamng")
public suspend fun timeWindowSec(`value`: Output) {
this.timeWindowSec = value
}
/**
* @param value A nested object resource
* Structure is documented below.
*/
@JvmName("qxvbmtldjclrfgun")
public suspend fun maxScaledDownReplicas(`value`: AutoscalerAutoscalingPolicyScaleDownControlMaxScaledDownReplicasArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.maxScaledDownReplicas = mapped
}
/**
* @param argument A nested object resource
* Structure is documented below.
*/
@JvmName("pfkhwyyfmfcqcrej")
public suspend fun maxScaledDownReplicas(argument: suspend AutoscalerAutoscalingPolicyScaleDownControlMaxScaledDownReplicasArgsBuilder.() -> Unit) {
val toBeMapped =
AutoscalerAutoscalingPolicyScaleDownControlMaxScaledDownReplicasArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.maxScaledDownReplicas = mapped
}
/**
* @param value How long back autoscaling should look when computing recommendations
* to include directives regarding slower scale down, as described above.
*/
@JvmName("bnbfjvstyhbxksvg")
public suspend fun timeWindowSec(`value`: Int?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.timeWindowSec = mapped
}
internal fun build(): AutoscalerAutoscalingPolicyScaleDownControlArgs =
AutoscalerAutoscalingPolicyScaleDownControlArgs(
maxScaledDownReplicas = maxScaledDownReplicas,
timeWindowSec = timeWindowSec,
)
}