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

com.pulumi.gcp.dataproc.kotlin.inputs.WorkflowTemplateJobPrestoJobArgs.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.WorkflowTemplateJobPrestoJobArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Boolean
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import kotlin.jvm.JvmName

/**
 *
 * @property clientTags Presto client tags to attach to this query
 * @property continueOnFailure Whether to continue executing queries if a query fails. The default value is `false`. Setting to `true` can be useful when executing independent parallel queries.
 * @property loggingConfig The runtime log config for job execution.
 * @property outputFormat The format in which query output will be displayed. See the Presto documentation for supported output formats
 * @property properties A mapping of property names to values. Used to set Presto (https://prestodb.io/docs/current/sql/set-session.html) Equivalent to using the --session flag in the Presto CLI
 * @property queryFileUri The HCFS URI of the script that contains SQL queries.
 * @property queryList A list of queries.
 */
public data class WorkflowTemplateJobPrestoJobArgs(
    public val clientTags: Output>? = null,
    public val continueOnFailure: Output? = null,
    public val loggingConfig: Output? = null,
    public val outputFormat: Output? = null,
    public val properties: Output>? = null,
    public val queryFileUri: Output? = null,
    public val queryList: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.dataproc.inputs.WorkflowTemplateJobPrestoJobArgs =
        com.pulumi.gcp.dataproc.inputs.WorkflowTemplateJobPrestoJobArgs.builder()
            .clientTags(clientTags?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .continueOnFailure(continueOnFailure?.applyValue({ args0 -> args0 }))
            .loggingConfig(loggingConfig?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .outputFormat(outputFormat?.applyValue({ args0 -> args0 }))
            .properties(
                properties?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            )
            .queryFileUri(queryFileUri?.applyValue({ args0 -> args0 }))
            .queryList(queryList?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) })).build()
}

/**
 * Builder for [WorkflowTemplateJobPrestoJobArgs].
 */
@PulumiTagMarker
public class WorkflowTemplateJobPrestoJobArgsBuilder internal constructor() {
    private var clientTags: Output>? = null

    private var continueOnFailure: Output? = null

    private var loggingConfig: Output? = null

    private var outputFormat: Output? = null

    private var properties: Output>? = null

    private var queryFileUri: Output? = null

    private var queryList: Output? = null

    /**
     * @param value Presto client tags to attach to this query
     */
    @JvmName("ilwqxmveajnifsbi")
    public suspend fun clientTags(`value`: Output>) {
        this.clientTags = value
    }

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

    /**
     * @param values Presto client tags to attach to this query
     */
    @JvmName("gfarqosqndwxwjqm")
    public suspend fun clientTags(values: List>) {
        this.clientTags = Output.all(values)
    }

    /**
     * @param value Whether to continue executing queries if a query fails. The default value is `false`. Setting to `true` can be useful when executing independent parallel queries.
     */
    @JvmName("ogiffysddhkgvxjw")
    public suspend fun continueOnFailure(`value`: Output) {
        this.continueOnFailure = value
    }

    /**
     * @param value The runtime log config for job execution.
     */
    @JvmName("lwcwrvgctkorsywd")
    public suspend fun loggingConfig(`value`: Output) {
        this.loggingConfig = value
    }

    /**
     * @param value The format in which query output will be displayed. See the Presto documentation for supported output formats
     */
    @JvmName("pcvtiiqctfhoeftw")
    public suspend fun outputFormat(`value`: Output) {
        this.outputFormat = value
    }

    /**
     * @param value A mapping of property names to values. Used to set Presto (https://prestodb.io/docs/current/sql/set-session.html) Equivalent to using the --session flag in the Presto CLI
     */
    @JvmName("fwlrrxaugwimaryq")
    public suspend fun properties(`value`: Output>) {
        this.properties = value
    }

    /**
     * @param value The HCFS URI of the script that contains SQL queries.
     */
    @JvmName("entminykouvxktxe")
    public suspend fun queryFileUri(`value`: Output) {
        this.queryFileUri = value
    }

    /**
     * @param value A list of queries.
     */
    @JvmName("owpvlyfbllotqdyy")
    public suspend fun queryList(`value`: Output) {
        this.queryList = value
    }

    /**
     * @param value Presto client tags to attach to this query
     */
    @JvmName("lropciuirqdptaku")
    public suspend fun clientTags(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.clientTags = mapped
    }

    /**
     * @param values Presto client tags to attach to this query
     */
    @JvmName("kuistbfieyqeyyws")
    public suspend fun clientTags(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.clientTags = mapped
    }

    /**
     * @param value Whether to continue executing queries if a query fails. The default value is `false`. Setting to `true` can be useful when executing independent parallel queries.
     */
    @JvmName("vcnliqvfnvguvisb")
    public suspend fun continueOnFailure(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.continueOnFailure = mapped
    }

    /**
     * @param value The runtime log config for job execution.
     */
    @JvmName("guyyylhodtnvflge")
    public suspend fun loggingConfig(`value`: WorkflowTemplateJobPrestoJobLoggingConfigArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.loggingConfig = mapped
    }

    /**
     * @param argument The runtime log config for job execution.
     */
    @JvmName("ycqmwnqpgvwqvqin")
    public suspend fun loggingConfig(argument: suspend WorkflowTemplateJobPrestoJobLoggingConfigArgsBuilder.() -> Unit) {
        val toBeMapped = WorkflowTemplateJobPrestoJobLoggingConfigArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.loggingConfig = mapped
    }

    /**
     * @param value The format in which query output will be displayed. See the Presto documentation for supported output formats
     */
    @JvmName("alkgfmlpniidegss")
    public suspend fun outputFormat(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.outputFormat = mapped
    }

    /**
     * @param value A mapping of property names to values. Used to set Presto (https://prestodb.io/docs/current/sql/set-session.html) Equivalent to using the --session flag in the Presto CLI
     */
    @JvmName("qubjoyagkflujjdq")
    public suspend fun properties(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.properties = mapped
    }

    /**
     * @param values A mapping of property names to values. Used to set Presto (https://prestodb.io/docs/current/sql/set-session.html) Equivalent to using the --session flag in the Presto CLI
     */
    @JvmName("dlhfsmfbrmeduatg")
    public fun properties(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.properties = mapped
    }

    /**
     * @param value The HCFS URI of the script that contains SQL queries.
     */
    @JvmName("rktflcxxhvlfwgdn")
    public suspend fun queryFileUri(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.queryFileUri = mapped
    }

    /**
     * @param value A list of queries.
     */
    @JvmName("dcfhpwsynhvhhvpt")
    public suspend fun queryList(`value`: WorkflowTemplateJobPrestoJobQueryListArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.queryList = mapped
    }

    /**
     * @param argument A list of queries.
     */
    @JvmName("pjwyjrsbrdrkrorw")
    public suspend fun queryList(argument: suspend WorkflowTemplateJobPrestoJobQueryListArgsBuilder.() -> Unit) {
        val toBeMapped = WorkflowTemplateJobPrestoJobQueryListArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.queryList = mapped
    }

    internal fun build(): WorkflowTemplateJobPrestoJobArgs = WorkflowTemplateJobPrestoJobArgs(
        clientTags = clientTags,
        continueOnFailure = continueOnFailure,
        loggingConfig = loggingConfig,
        outputFormat = outputFormat,
        properties = properties,
        queryFileUri = queryFileUri,
        queryList = queryList,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy