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

com.pulumi.gcp.compute.kotlin.inputs.RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayArgs.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: 8.10.0.0
Show newest version
@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.RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Double
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName

/**
 *
 * @property fixedDelay Specifies the value of the fixed delay interval.
 * Structure is documented below.
 * @property percentage The percentage of traffic (connections/operations/requests) on which delay will be introduced as part of fault injection.
 * The value must be between 0.0 and 100.0 inclusive.
 */
public data class RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayArgs(
    public val fixedDelay: Output,
    public val percentage: Output,
) :
    ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.compute.inputs.RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayArgs =
        com.pulumi.gcp.compute.inputs.RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayArgs.builder()
            .fixedDelay(fixedDelay.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .percentage(percentage.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayArgs].
 */
@PulumiTagMarker
public class RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayArgsBuilder internal constructor() {
    private var fixedDelay:
        Output? =
        null

    private var percentage: Output? = null

    /**
     * @param value Specifies the value of the fixed delay interval.
     * Structure is documented below.
     */
    @JvmName("iuclboiipoqyjgwe")
    public suspend fun fixedDelay(`value`: Output) {
        this.fixedDelay = value
    }

    /**
     * @param value The percentage of traffic (connections/operations/requests) on which delay will be introduced as part of fault injection.
     * The value must be between 0.0 and 100.0 inclusive.
     */
    @JvmName("xisounhfhvybjsdq")
    public suspend fun percentage(`value`: Output) {
        this.percentage = value
    }

    /**
     * @param value Specifies the value of the fixed delay interval.
     * Structure is documented below.
     */
    @JvmName("yaailyhfwamacprc")
    public suspend fun fixedDelay(`value`: RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayFixedDelayArgs) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.fixedDelay = mapped
    }

    /**
     * @param argument Specifies the value of the fixed delay interval.
     * Structure is documented below.
     */
    @JvmName("ffwssnhngdoklgne")
    public suspend fun fixedDelay(argument: suspend RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayFixedDelayArgsBuilder.() -> Unit) {
        val toBeMapped =
            RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayFixedDelayArgsBuilder().applySuspend {
                argument()
            }.build()
        val mapped = of(toBeMapped)
        this.fixedDelay = mapped
    }

    /**
     * @param value The percentage of traffic (connections/operations/requests) on which delay will be introduced as part of fault injection.
     * The value must be between 0.0 and 100.0 inclusive.
     */
    @JvmName("stcljfnmngcfvvin")
    public suspend fun percentage(`value`: Double) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.percentage = mapped
    }

    internal fun build(): RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayArgs =
        RegionUrlMapPathMatcherPathRuleRouteActionFaultInjectionPolicyDelayArgs(
            fixedDelay = fixedDelay ?: throw PulumiNullFieldException("fixedDelay"),
            percentage = percentage ?: throw PulumiNullFieldException("percentage"),
        )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy