com.pulumi.cloudflare.kotlin.inputs.LoadBalancerPoolOriginArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-cloudflare-kotlin Show documentation
Show all versions of pulumi-cloudflare-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.
The newest version!
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.cloudflare.kotlin.inputs
import com.pulumi.cloudflare.inputs.LoadBalancerPoolOriginArgs.builder
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 kotlin.Boolean
import kotlin.Double
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName
/**
*
* @property address The IP address (IPv4 or IPv6) of the origin, or the publicly addressable hostname.
* @property enabled Whether this origin is enabled. Disabled origins will not receive traffic and are excluded from health checks. Defaults to `true`.
* @property headers HTTP request headers.
* @property name A human-identifiable name for the origin.
* @property virtualNetworkId The virtual network subnet ID the origin belongs in. Virtual network must also belong to the account.
* @property weight The weight (0.01 - 1.00) of this origin, relative to other origins in the pool. Equal values mean equal weighting. A weight of 0 means traffic will not be sent to this origin, but health is still checked. When `origin_steering.policy="least_outstanding_requests"`, weight is used to scale the origin's outstanding requests. When `origin_steering.policy="least_connections"`, weight is used to scale the origin's open connections. Defaults to `1`.
*/
public data class LoadBalancerPoolOriginArgs(
public val address: Output,
public val enabled: Output? = null,
public val headers: Output>? = null,
public val name: Output,
public val virtualNetworkId: Output? = null,
public val weight: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.cloudflare.inputs.LoadBalancerPoolOriginArgs =
com.pulumi.cloudflare.inputs.LoadBalancerPoolOriginArgs.builder()
.address(address.applyValue({ args0 -> args0 }))
.enabled(enabled?.applyValue({ args0 -> args0 }))
.headers(
headers?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
})
}),
)
.name(name.applyValue({ args0 -> args0 }))
.virtualNetworkId(virtualNetworkId?.applyValue({ args0 -> args0 }))
.weight(weight?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [LoadBalancerPoolOriginArgs].
*/
@PulumiTagMarker
public class LoadBalancerPoolOriginArgsBuilder internal constructor() {
private var address: Output? = null
private var enabled: Output? = null
private var headers: Output>? = null
private var name: Output? = null
private var virtualNetworkId: Output? = null
private var weight: Output? = null
/**
* @param value The IP address (IPv4 or IPv6) of the origin, or the publicly addressable hostname.
*/
@JvmName("duymxajaugnjrpba")
public suspend fun address(`value`: Output) {
this.address = value
}
/**
* @param value Whether this origin is enabled. Disabled origins will not receive traffic and are excluded from health checks. Defaults to `true`.
*/
@JvmName("wdcwueltittjgiwn")
public suspend fun enabled(`value`: Output) {
this.enabled = value
}
/**
* @param value HTTP request headers.
*/
@JvmName("umnmuxmadtmxthpj")
public suspend fun headers(`value`: Output>) {
this.headers = value
}
@JvmName("dbwjjmnwpmheiivn")
public suspend fun headers(vararg values: Output) {
this.headers = Output.all(values.asList())
}
/**
* @param values HTTP request headers.
*/
@JvmName("fdltousylynlffqh")
public suspend fun headers(values: List