All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.kubernetes.apps.v1beta2.kotlin.inputs.StatefulSetStatusArgs.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 4.18.2.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.kubernetes.apps.v1beta2.kotlin.inputs

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 com.pulumi.kubernetes.apps.v1beta2.inputs.StatefulSetStatusArgs.builder
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 * StatefulSetStatus represents the current state of a StatefulSet.
 * @property collisionCount collisionCount is the count of hash collisions for the StatefulSet. The StatefulSet controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ControllerRevision.
 * @property conditions Represents the latest available observations of a statefulset's current state.
 * @property currentReplicas currentReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by currentRevision.
 * @property currentRevision currentRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [0,currentReplicas).
 * @property observedGeneration observedGeneration is the most recent generation observed for this StatefulSet. It corresponds to the StatefulSet's generation, which is updated on mutation by the API Server.
 * @property readyReplicas readyReplicas is the number of Pods created by the StatefulSet controller that have a Ready Condition.
 * @property replicas replicas is the number of Pods created by the StatefulSet controller.
 * @property updateRevision updateRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [replicas-updatedReplicas,replicas)
 * @property updatedReplicas updatedReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by updateRevision.
 */
public data class StatefulSetStatusArgs(
    public val collisionCount: Output? = null,
    public val conditions: Output>? = null,
    public val currentReplicas: Output? = null,
    public val currentRevision: Output? = null,
    public val observedGeneration: Output? = null,
    public val readyReplicas: Output? = null,
    public val replicas: Output,
    public val updateRevision: Output? = null,
    public val updatedReplicas: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.kubernetes.apps.v1beta2.inputs.StatefulSetStatusArgs =
        com.pulumi.kubernetes.apps.v1beta2.inputs.StatefulSetStatusArgs.builder()
            .collisionCount(collisionCount?.applyValue({ args0 -> args0 }))
            .conditions(
                conditions?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .currentReplicas(currentReplicas?.applyValue({ args0 -> args0 }))
            .currentRevision(currentRevision?.applyValue({ args0 -> args0 }))
            .observedGeneration(observedGeneration?.applyValue({ args0 -> args0 }))
            .readyReplicas(readyReplicas?.applyValue({ args0 -> args0 }))
            .replicas(replicas.applyValue({ args0 -> args0 }))
            .updateRevision(updateRevision?.applyValue({ args0 -> args0 }))
            .updatedReplicas(updatedReplicas?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [StatefulSetStatusArgs].
 */
@PulumiTagMarker
public class StatefulSetStatusArgsBuilder internal constructor() {
    private var collisionCount: Output? = null

    private var conditions: Output>? = null

    private var currentReplicas: Output? = null

    private var currentRevision: Output? = null

    private var observedGeneration: Output? = null

    private var readyReplicas: Output? = null

    private var replicas: Output? = null

    private var updateRevision: Output? = null

    private var updatedReplicas: Output? = null

    /**
     * @param value collisionCount is the count of hash collisions for the StatefulSet. The StatefulSet controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ControllerRevision.
     */
    @JvmName("viunyfylohiibxqp")
    public suspend fun collisionCount(`value`: Output) {
        this.collisionCount = value
    }

    /**
     * @param value Represents the latest available observations of a statefulset's current state.
     */
    @JvmName("ghtrdwkhxicvuvmw")
    public suspend fun conditions(`value`: Output>) {
        this.conditions = value
    }

    @JvmName("hchxscarpcssdguo")
    public suspend fun conditions(vararg values: Output) {
        this.conditions = Output.all(values.asList())
    }

    /**
     * @param values Represents the latest available observations of a statefulset's current state.
     */
    @JvmName("mrummmjqawjodmqv")
    public suspend fun conditions(values: List>) {
        this.conditions = Output.all(values)
    }

    /**
     * @param value currentReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by currentRevision.
     */
    @JvmName("iplcdelsiwdjhuge")
    public suspend fun currentReplicas(`value`: Output) {
        this.currentReplicas = value
    }

    /**
     * @param value currentRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [0,currentReplicas).
     */
    @JvmName("vgudrkyxfltnjhqf")
    public suspend fun currentRevision(`value`: Output) {
        this.currentRevision = value
    }

    /**
     * @param value observedGeneration is the most recent generation observed for this StatefulSet. It corresponds to the StatefulSet's generation, which is updated on mutation by the API Server.
     */
    @JvmName("wiygguhrxcsoxbtq")
    public suspend fun observedGeneration(`value`: Output) {
        this.observedGeneration = value
    }

    /**
     * @param value readyReplicas is the number of Pods created by the StatefulSet controller that have a Ready Condition.
     */
    @JvmName("yefqyjubmckgrypd")
    public suspend fun readyReplicas(`value`: Output) {
        this.readyReplicas = value
    }

    /**
     * @param value replicas is the number of Pods created by the StatefulSet controller.
     */
    @JvmName("pfdycjdbgmavmprw")
    public suspend fun replicas(`value`: Output) {
        this.replicas = value
    }

    /**
     * @param value updateRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [replicas-updatedReplicas,replicas)
     */
    @JvmName("ialqcedulnwiolhf")
    public suspend fun updateRevision(`value`: Output) {
        this.updateRevision = value
    }

    /**
     * @param value updatedReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by updateRevision.
     */
    @JvmName("jiyctecigarxwwor")
    public suspend fun updatedReplicas(`value`: Output) {
        this.updatedReplicas = value
    }

    /**
     * @param value collisionCount is the count of hash collisions for the StatefulSet. The StatefulSet controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ControllerRevision.
     */
    @JvmName("vpfksetqhdgyyagc")
    public suspend fun collisionCount(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.collisionCount = mapped
    }

    /**
     * @param value Represents the latest available observations of a statefulset's current state.
     */
    @JvmName("uheuogaelktbabun")
    public suspend fun conditions(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.conditions = mapped
    }

    /**
     * @param argument Represents the latest available observations of a statefulset's current state.
     */
    @JvmName("nhqlvyvpaxvnlpsx")
    public suspend fun conditions(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            StatefulSetConditionArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.conditions = mapped
    }

    /**
     * @param argument Represents the latest available observations of a statefulset's current state.
     */
    @JvmName("pbxgsujktbdiediu")
    public suspend fun conditions(vararg argument: suspend StatefulSetConditionArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            StatefulSetConditionArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.conditions = mapped
    }

    /**
     * @param argument Represents the latest available observations of a statefulset's current state.
     */
    @JvmName("vnpmjiowljkyddwe")
    public suspend fun conditions(argument: suspend StatefulSetConditionArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(StatefulSetConditionArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.conditions = mapped
    }

    /**
     * @param values Represents the latest available observations of a statefulset's current state.
     */
    @JvmName("vbbkyfqjfwvrbumh")
    public suspend fun conditions(vararg values: StatefulSetConditionArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.conditions = mapped
    }

    /**
     * @param value currentReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by currentRevision.
     */
    @JvmName("nbwbsmftjnpstuqb")
    public suspend fun currentReplicas(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.currentReplicas = mapped
    }

    /**
     * @param value currentRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [0,currentReplicas).
     */
    @JvmName("fylerrmwdgsdivxr")
    public suspend fun currentRevision(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.currentRevision = mapped
    }

    /**
     * @param value observedGeneration is the most recent generation observed for this StatefulSet. It corresponds to the StatefulSet's generation, which is updated on mutation by the API Server.
     */
    @JvmName("qlxhrqidrkpssbhc")
    public suspend fun observedGeneration(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.observedGeneration = mapped
    }

    /**
     * @param value readyReplicas is the number of Pods created by the StatefulSet controller that have a Ready Condition.
     */
    @JvmName("jijiqjoscxiwwwyy")
    public suspend fun readyReplicas(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.readyReplicas = mapped
    }

    /**
     * @param value replicas is the number of Pods created by the StatefulSet controller.
     */
    @JvmName("djtcmoxsemhwvwco")
    public suspend fun replicas(`value`: Int) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.replicas = mapped
    }

    /**
     * @param value updateRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [replicas-updatedReplicas,replicas)
     */
    @JvmName("eejwbeeagokanmkq")
    public suspend fun updateRevision(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.updateRevision = mapped
    }

    /**
     * @param value updatedReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by updateRevision.
     */
    @JvmName("fcmmtpesmoagymld")
    public suspend fun updatedReplicas(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.updatedReplicas = mapped
    }

    internal fun build(): StatefulSetStatusArgs = StatefulSetStatusArgs(
        collisionCount = collisionCount,
        conditions = conditions,
        currentReplicas = currentReplicas,
        currentRevision = currentRevision,
        observedGeneration = observedGeneration,
        readyReplicas = readyReplicas,
        replicas = replicas ?: throw PulumiNullFieldException("replicas"),
        updateRevision = updateRevision,
        updatedReplicas = updatedReplicas,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy