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

com.pulumi.gcp.dataproc.kotlin.inputs.ClusterClusterConfigMasterConfigAcceleratorArgs.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.dataproc.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.dataproc.inputs.ClusterClusterConfigMasterConfigAcceleratorArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName

/**
 *
 * @property acceleratorCount The number of the accelerator cards of this type exposed to this instance. Often restricted to one of `1`, `2`, `4`, or `8`.
 * > The Cloud Dataproc API can return unintuitive error messages when using accelerators; even when you have defined an accelerator, Auto Zone Placement does not exclusively select
 * zones that have that accelerator available. If you get a 400 error that the accelerator can't be found, this is a likely cause. Make sure you check [accelerator availability by zone](https://cloud.google.com/compute/docs/reference/rest/v1/acceleratorTypes/list)
 * if you are trying to use accelerators in a given zone.
 * - - -
 * @property acceleratorType The short name of the accelerator type to expose to this instance. For example, `nvidia-tesla-k80`.
 */
public data class ClusterClusterConfigMasterConfigAcceleratorArgs(
    public val acceleratorCount: Output,
    public val acceleratorType: Output,
) :
    ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.dataproc.inputs.ClusterClusterConfigMasterConfigAcceleratorArgs =
        com.pulumi.gcp.dataproc.inputs.ClusterClusterConfigMasterConfigAcceleratorArgs.builder()
            .acceleratorCount(acceleratorCount.applyValue({ args0 -> args0 }))
            .acceleratorType(acceleratorType.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [ClusterClusterConfigMasterConfigAcceleratorArgs].
 */
@PulumiTagMarker
public class ClusterClusterConfigMasterConfigAcceleratorArgsBuilder internal constructor() {
    private var acceleratorCount: Output? = null

    private var acceleratorType: Output? = null

    /**
     * @param value The number of the accelerator cards of this type exposed to this instance. Often restricted to one of `1`, `2`, `4`, or `8`.
     * > The Cloud Dataproc API can return unintuitive error messages when using accelerators; even when you have defined an accelerator, Auto Zone Placement does not exclusively select
     * zones that have that accelerator available. If you get a 400 error that the accelerator can't be found, this is a likely cause. Make sure you check [accelerator availability by zone](https://cloud.google.com/compute/docs/reference/rest/v1/acceleratorTypes/list)
     * if you are trying to use accelerators in a given zone.
     * - - -
     */
    @JvmName("pgyeufmsviyolndj")
    public suspend fun acceleratorCount(`value`: Output) {
        this.acceleratorCount = value
    }

    /**
     * @param value The short name of the accelerator type to expose to this instance. For example, `nvidia-tesla-k80`.
     */
    @JvmName("xmkvevindflcplxb")
    public suspend fun acceleratorType(`value`: Output) {
        this.acceleratorType = value
    }

    /**
     * @param value The number of the accelerator cards of this type exposed to this instance. Often restricted to one of `1`, `2`, `4`, or `8`.
     * > The Cloud Dataproc API can return unintuitive error messages when using accelerators; even when you have defined an accelerator, Auto Zone Placement does not exclusively select
     * zones that have that accelerator available. If you get a 400 error that the accelerator can't be found, this is a likely cause. Make sure you check [accelerator availability by zone](https://cloud.google.com/compute/docs/reference/rest/v1/acceleratorTypes/list)
     * if you are trying to use accelerators in a given zone.
     * - - -
     */
    @JvmName("pibxpsjpvmgwfijn")
    public suspend fun acceleratorCount(`value`: Int) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.acceleratorCount = mapped
    }

    /**
     * @param value The short name of the accelerator type to expose to this instance. For example, `nvidia-tesla-k80`.
     */
    @JvmName("alxwptkmrgwbtvom")
    public suspend fun acceleratorType(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.acceleratorType = mapped
    }

    internal fun build(): ClusterClusterConfigMasterConfigAcceleratorArgs =
        ClusterClusterConfigMasterConfigAcceleratorArgs(
            acceleratorCount = acceleratorCount ?: throw PulumiNullFieldException("acceleratorCount"),
            acceleratorType = acceleratorType ?: throw PulumiNullFieldException("acceleratorType"),
        )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy