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

com.pulumi.googlenative.pubsub.v1.kotlin.inputs.RetryPolicyArgs.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.

The newest version!
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.googlenative.pubsub.v1.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.googlenative.pubsub.v1.inputs.RetryPolicyArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName

/**
 * A policy that specifies how Cloud Pub/Sub retries message delivery. Retry delay will be exponential based on provided minimum and maximum backoffs. https://en.wikipedia.org/wiki/Exponential_backoff. RetryPolicy will be triggered on NACKs or acknowledgement deadline exceeded events for a given message. Retry Policy is implemented on a best effort basis. At times, the delay between consecutive deliveries may not match the configuration. That is, delay can be more or less than configured backoff.
 * @property maximumBackoff The maximum delay between consecutive deliveries of a given message. Value should be between 0 and 600 seconds. Defaults to 600 seconds.
 * @property minimumBackoff The minimum delay between consecutive deliveries of a given message. Value should be between 0 and 600 seconds. Defaults to 10 seconds.
 */
public data class RetryPolicyArgs(
    public val maximumBackoff: Output? = null,
    public val minimumBackoff: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.googlenative.pubsub.v1.inputs.RetryPolicyArgs =
        com.pulumi.googlenative.pubsub.v1.inputs.RetryPolicyArgs.builder()
            .maximumBackoff(maximumBackoff?.applyValue({ args0 -> args0 }))
            .minimumBackoff(minimumBackoff?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [RetryPolicyArgs].
 */
@PulumiTagMarker
public class RetryPolicyArgsBuilder internal constructor() {
    private var maximumBackoff: Output? = null

    private var minimumBackoff: Output? = null

    /**
     * @param value The maximum delay between consecutive deliveries of a given message. Value should be between 0 and 600 seconds. Defaults to 600 seconds.
     */
    @JvmName("oshvtxggpasjeljd")
    public suspend fun maximumBackoff(`value`: Output) {
        this.maximumBackoff = value
    }

    /**
     * @param value The minimum delay between consecutive deliveries of a given message. Value should be between 0 and 600 seconds. Defaults to 10 seconds.
     */
    @JvmName("xritdroxmcktuuih")
    public suspend fun minimumBackoff(`value`: Output) {
        this.minimumBackoff = value
    }

    /**
     * @param value The maximum delay between consecutive deliveries of a given message. Value should be between 0 and 600 seconds. Defaults to 600 seconds.
     */
    @JvmName("bedybdjkewmicxqe")
    public suspend fun maximumBackoff(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.maximumBackoff = mapped
    }

    /**
     * @param value The minimum delay between consecutive deliveries of a given message. Value should be between 0 and 600 seconds. Defaults to 10 seconds.
     */
    @JvmName("rlpsanxdumysjcpx")
    public suspend fun minimumBackoff(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.minimumBackoff = mapped
    }

    internal fun build(): RetryPolicyArgs = RetryPolicyArgs(
        maximumBackoff = maximumBackoff,
        minimumBackoff = minimumBackoff,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy