![JAR search and dependency download from the Maven repository](/logo.png)
com.pulumi.awsnative.ec2.kotlin.inputs.SpotFleetSpotCapacityRebalanceArgs.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.awsnative.ec2.kotlin.inputs
import com.pulumi.awsnative.ec2.inputs.SpotFleetSpotCapacityRebalanceArgs.builder
import com.pulumi.awsnative.ec2.kotlin.enums.SpotFleetSpotCapacityRebalanceReplacementStrategy
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Int
import kotlin.Suppress
import kotlin.jvm.JvmName
/**
*
* @property replacementStrategy The replacement strategy to use. Only available for fleets of type `maintain` .
* `launch` - Spot Fleet launches a new replacement Spot Instance when a rebalance notification is emitted for an existing Spot Instance in the fleet. Spot Fleet does not terminate the instances that receive a rebalance notification. You can terminate the old instances, or you can leave them running. You are charged for all instances while they are running.
* `launch-before-terminate` - Spot Fleet launches a new replacement Spot Instance when a rebalance notification is emitted for an existing Spot Instance in the fleet, and then, after a delay that you specify (in `TerminationDelay` ), terminates the instances that received a rebalance notification.
* @property terminationDelay The amount of time (in seconds) that Amazon EC2 waits before terminating the old Spot Instance after launching a new replacement Spot Instance.
* Required when `ReplacementStrategy` is set to `launch-before-terminate` .
* Not valid when `ReplacementStrategy` is set to `launch` .
* Valid values: Minimum value of `120` seconds. Maximum value of `7200` seconds.
*/
public data class SpotFleetSpotCapacityRebalanceArgs(
public val replacementStrategy: Output? = null,
public val terminationDelay: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.awsnative.ec2.inputs.SpotFleetSpotCapacityRebalanceArgs =
com.pulumi.awsnative.ec2.inputs.SpotFleetSpotCapacityRebalanceArgs.builder()
.replacementStrategy(
replacementStrategy?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.terminationDelay(terminationDelay?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [SpotFleetSpotCapacityRebalanceArgs].
*/
@PulumiTagMarker
public class SpotFleetSpotCapacityRebalanceArgsBuilder internal constructor() {
private var replacementStrategy: Output? = null
private var terminationDelay: Output? = null
/**
* @param value The replacement strategy to use. Only available for fleets of type `maintain` .
* `launch` - Spot Fleet launches a new replacement Spot Instance when a rebalance notification is emitted for an existing Spot Instance in the fleet. Spot Fleet does not terminate the instances that receive a rebalance notification. You can terminate the old instances, or you can leave them running. You are charged for all instances while they are running.
* `launch-before-terminate` - Spot Fleet launches a new replacement Spot Instance when a rebalance notification is emitted for an existing Spot Instance in the fleet, and then, after a delay that you specify (in `TerminationDelay` ), terminates the instances that received a rebalance notification.
*/
@JvmName("ylhfnlxsfyduwqxr")
public suspend fun replacementStrategy(`value`: Output) {
this.replacementStrategy = value
}
/**
* @param value The amount of time (in seconds) that Amazon EC2 waits before terminating the old Spot Instance after launching a new replacement Spot Instance.
* Required when `ReplacementStrategy` is set to `launch-before-terminate` .
* Not valid when `ReplacementStrategy` is set to `launch` .
* Valid values: Minimum value of `120` seconds. Maximum value of `7200` seconds.
*/
@JvmName("mxsfycjqiyyadqoy")
public suspend fun terminationDelay(`value`: Output) {
this.terminationDelay = value
}
/**
* @param value The replacement strategy to use. Only available for fleets of type `maintain` .
* `launch` - Spot Fleet launches a new replacement Spot Instance when a rebalance notification is emitted for an existing Spot Instance in the fleet. Spot Fleet does not terminate the instances that receive a rebalance notification. You can terminate the old instances, or you can leave them running. You are charged for all instances while they are running.
* `launch-before-terminate` - Spot Fleet launches a new replacement Spot Instance when a rebalance notification is emitted for an existing Spot Instance in the fleet, and then, after a delay that you specify (in `TerminationDelay` ), terminates the instances that received a rebalance notification.
*/
@JvmName("bnasqykhreubtlgr")
public suspend fun replacementStrategy(`value`: SpotFleetSpotCapacityRebalanceReplacementStrategy?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.replacementStrategy = mapped
}
/**
* @param value The amount of time (in seconds) that Amazon EC2 waits before terminating the old Spot Instance after launching a new replacement Spot Instance.
* Required when `ReplacementStrategy` is set to `launch-before-terminate` .
* Not valid when `ReplacementStrategy` is set to `launch` .
* Valid values: Minimum value of `120` seconds. Maximum value of `7200` seconds.
*/
@JvmName("vewgwfmbpjnvewym")
public suspend fun terminationDelay(`value`: Int?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.terminationDelay = mapped
}
internal fun build(): SpotFleetSpotCapacityRebalanceArgs = SpotFleetSpotCapacityRebalanceArgs(
replacementStrategy = replacementStrategy,
terminationDelay = terminationDelay,
)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy