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

com.pulumi.azure.iot.kotlin.TimeSeriesInsightsGen2EnvironmentArgs.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: 6.15.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azure.iot.kotlin

import com.pulumi.azure.iot.TimeSeriesInsightsGen2EnvironmentArgs.builder
import com.pulumi.azure.iot.kotlin.inputs.TimeSeriesInsightsGen2EnvironmentStorageArgs
import com.pulumi.azure.iot.kotlin.inputs.TimeSeriesInsightsGen2EnvironmentStorageArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import kotlin.jvm.JvmName

/**
 * Manages an Azure IoT Time Series Insights Gen2 Environment.
 * ## Example Usage
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as azure from "@pulumi/azure";
 * const example = new azure.core.ResourceGroup("example", {
 *     name: "example-resources",
 *     location: "West Europe",
 * });
 * const storage = new azure.storage.Account("storage", {
 *     name: "example",
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     accountTier: "Standard",
 *     accountReplicationType: "LRS",
 * });
 * const exampleTimeSeriesInsightsGen2Environment = new azure.iot.TimeSeriesInsightsGen2Environment("example", {
 *     name: "example",
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     skuName: "L1",
 *     warmStoreDataRetentionTime: "P30D",
 *     idProperties: ["id"],
 *     storage: {
 *         name: storage.name,
 *         key: storage.primaryAccessKey,
 *     },
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_azure as azure
 * example = azure.core.ResourceGroup("example",
 *     name="example-resources",
 *     location="West Europe")
 * storage = azure.storage.Account("storage",
 *     name="example",
 *     location=example.location,
 *     resource_group_name=example.name,
 *     account_tier="Standard",
 *     account_replication_type="LRS")
 * example_time_series_insights_gen2_environment = azure.iot.TimeSeriesInsightsGen2Environment("example",
 *     name="example",
 *     location=example.location,
 *     resource_group_name=example.name,
 *     sku_name="L1",
 *     warm_store_data_retention_time="P30D",
 *     id_properties=["id"],
 *     storage={
 *         "name": storage.name,
 *         "key": storage.primary_access_key,
 *     })
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Azure = Pulumi.Azure;
 * return await Deployment.RunAsync(() =>
 * {
 *     var example = new Azure.Core.ResourceGroup("example", new()
 *     {
 *         Name = "example-resources",
 *         Location = "West Europe",
 *     });
 *     var storage = new Azure.Storage.Account("storage", new()
 *     {
 *         Name = "example",
 *         Location = example.Location,
 *         ResourceGroupName = example.Name,
 *         AccountTier = "Standard",
 *         AccountReplicationType = "LRS",
 *     });
 *     var exampleTimeSeriesInsightsGen2Environment = new Azure.Iot.TimeSeriesInsightsGen2Environment("example", new()
 *     {
 *         Name = "example",
 *         Location = example.Location,
 *         ResourceGroupName = example.Name,
 *         SkuName = "L1",
 *         WarmStoreDataRetentionTime = "P30D",
 *         IdProperties = new[]
 *         {
 *             "id",
 *         },
 *         Storage = new Azure.Iot.Inputs.TimeSeriesInsightsGen2EnvironmentStorageArgs
 *         {
 *             Name = storage.Name,
 *             Key = storage.PrimaryAccessKey,
 *         },
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/iot"
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/storage"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
 * 			Name:     pulumi.String("example-resources"),
 * 			Location: pulumi.String("West Europe"),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		storage, err := storage.NewAccount(ctx, "storage", &storage.AccountArgs{
 * 			Name:                   pulumi.String("example"),
 * 			Location:               example.Location,
 * 			ResourceGroupName:      example.Name,
 * 			AccountTier:            pulumi.String("Standard"),
 * 			AccountReplicationType: pulumi.String("LRS"),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		_, err = iot.NewTimeSeriesInsightsGen2Environment(ctx, "example", &iot.TimeSeriesInsightsGen2EnvironmentArgs{
 * 			Name:                       pulumi.String("example"),
 * 			Location:                   example.Location,
 * 			ResourceGroupName:          example.Name,
 * 			SkuName:                    pulumi.String("L1"),
 * 			WarmStoreDataRetentionTime: pulumi.String("P30D"),
 * 			IdProperties: pulumi.StringArray{
 * 				pulumi.String("id"),
 * 			},
 * 			Storage: &iot.TimeSeriesInsightsGen2EnvironmentStorageArgs{
 * 				Name: storage.Name,
 * 				Key:  storage.PrimaryAccessKey,
 * 			},
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		return nil
 * 	})
 * }
 * ```
 * ```java
 * package generated_program;
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azure.core.ResourceGroup;
 * import com.pulumi.azure.core.ResourceGroupArgs;
 * import com.pulumi.azure.storage.Account;
 * import com.pulumi.azure.storage.AccountArgs;
 * import com.pulumi.azure.iot.TimeSeriesInsightsGen2Environment;
 * import com.pulumi.azure.iot.TimeSeriesInsightsGen2EnvironmentArgs;
 * import com.pulumi.azure.iot.inputs.TimeSeriesInsightsGen2EnvironmentStorageArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 *     public static void stack(Context ctx) {
 *         var example = new ResourceGroup("example", ResourceGroupArgs.builder()
 *             .name("example-resources")
 *             .location("West Europe")
 *             .build());
 *         var storage = new Account("storage", AccountArgs.builder()
 *             .name("example")
 *             .location(example.location())
 *             .resourceGroupName(example.name())
 *             .accountTier("Standard")
 *             .accountReplicationType("LRS")
 *             .build());
 *         var exampleTimeSeriesInsightsGen2Environment = new TimeSeriesInsightsGen2Environment("exampleTimeSeriesInsightsGen2Environment", TimeSeriesInsightsGen2EnvironmentArgs.builder()
 *             .name("example")
 *             .location(example.location())
 *             .resourceGroupName(example.name())
 *             .skuName("L1")
 *             .warmStoreDataRetentionTime("P30D")
 *             .idProperties("id")
 *             .storage(TimeSeriesInsightsGen2EnvironmentStorageArgs.builder()
 *                 .name(storage.name())
 *                 .key(storage.primaryAccessKey())
 *                 .build())
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   example:
 *     type: azure:core:ResourceGroup
 *     properties:
 *       name: example-resources
 *       location: West Europe
 *   storage:
 *     type: azure:storage:Account
 *     properties:
 *       name: example
 *       location: ${example.location}
 *       resourceGroupName: ${example.name}
 *       accountTier: Standard
 *       accountReplicationType: LRS
 *   exampleTimeSeriesInsightsGen2Environment:
 *     type: azure:iot:TimeSeriesInsightsGen2Environment
 *     name: example
 *     properties:
 *       name: example
 *       location: ${example.location}
 *       resourceGroupName: ${example.name}
 *       skuName: L1
 *       warmStoreDataRetentionTime: P30D
 *       idProperties:
 *         - id
 *       storage:
 *         name: ${storage.name}
 *         key: ${storage.primaryAccessKey}
 * ```
 * 
 * ## Import
 * Azure IoT Time Series Insights Gen2 Environment can be imported using the `resource id`, e.g.
 * ```sh
 * $ pulumi import azure:iot/timeSeriesInsightsGen2Environment:TimeSeriesInsightsGen2Environment example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/example/providers/Microsoft.TimeSeriesInsights/environments/example
 * ```
 * @property idProperties A list of property ids for the Azure IoT Time Series Insights Gen2 Environment. Changing this forces a new resource to be created.
 * @property location Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
 * @property name Specifies the name of the Azure IoT Time Series Insights Gen2 Environment. Changing this forces a new resource to be created. Must be globally unique.
 * @property resourceGroupName The name of the resource group in which to create the Azure IoT Time Series Insights Gen2 Environment. Changing this forces a new resource to be created.
 * @property skuName Specifies the SKU Name for this IoT Time Series Insights Gen2 Environment. Currently it supports only `L1`. For gen2, capacity cannot be specified. Changing this forces a new resource to be created.
 * @property storage A `storage` block as defined below.
 * @property tags A mapping of tags to assign to the resource.
 * @property warmStoreDataRetentionTime Specifies the ISO8601 timespan specifying the minimum number of days the environment's events will be available for query.
 */
public data class TimeSeriesInsightsGen2EnvironmentArgs(
    public val idProperties: Output>? = null,
    public val location: Output? = null,
    public val name: Output? = null,
    public val resourceGroupName: Output? = null,
    public val skuName: Output? = null,
    public val storage: Output? = null,
    public val tags: Output>? = null,
    public val warmStoreDataRetentionTime: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azure.iot.TimeSeriesInsightsGen2EnvironmentArgs =
        com.pulumi.azure.iot.TimeSeriesInsightsGen2EnvironmentArgs.builder()
            .idProperties(idProperties?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .location(location?.applyValue({ args0 -> args0 }))
            .name(name?.applyValue({ args0 -> args0 }))
            .resourceGroupName(resourceGroupName?.applyValue({ args0 -> args0 }))
            .skuName(skuName?.applyValue({ args0 -> args0 }))
            .storage(storage?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .tags(tags?.applyValue({ args0 -> args0.map({ args0 -> args0.key.to(args0.value) }).toMap() }))
            .warmStoreDataRetentionTime(warmStoreDataRetentionTime?.applyValue({ args0 -> args0 })).build()
}

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

    private var location: Output? = null

    private var name: Output? = null

    private var resourceGroupName: Output? = null

    private var skuName: Output? = null

    private var storage: Output? = null

    private var tags: Output>? = null

    private var warmStoreDataRetentionTime: Output? = null

    /**
     * @param value A list of property ids for the Azure IoT Time Series Insights Gen2 Environment. Changing this forces a new resource to be created.
     */
    @JvmName("ldtsybtroqvajtnc")
    public suspend fun idProperties(`value`: Output>) {
        this.idProperties = value
    }

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

    /**
     * @param values A list of property ids for the Azure IoT Time Series Insights Gen2 Environment. Changing this forces a new resource to be created.
     */
    @JvmName("lyiukflfiuecahjn")
    public suspend fun idProperties(values: List>) {
        this.idProperties = Output.all(values)
    }

    /**
     * @param value Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
     */
    @JvmName("gdxkibjhuborkydn")
    public suspend fun location(`value`: Output) {
        this.location = value
    }

    /**
     * @param value Specifies the name of the Azure IoT Time Series Insights Gen2 Environment. Changing this forces a new resource to be created. Must be globally unique.
     */
    @JvmName("xexqqlbhsbitknnk")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value The name of the resource group in which to create the Azure IoT Time Series Insights Gen2 Environment. Changing this forces a new resource to be created.
     */
    @JvmName("ffuahbvvefruujxh")
    public suspend fun resourceGroupName(`value`: Output) {
        this.resourceGroupName = value
    }

    /**
     * @param value Specifies the SKU Name for this IoT Time Series Insights Gen2 Environment. Currently it supports only `L1`. For gen2, capacity cannot be specified. Changing this forces a new resource to be created.
     */
    @JvmName("jiiucwhhwbpymrlt")
    public suspend fun skuName(`value`: Output) {
        this.skuName = value
    }

    /**
     * @param value A `storage` block as defined below.
     */
    @JvmName("qlwwupvxhlyiekec")
    public suspend fun storage(`value`: Output) {
        this.storage = value
    }

    /**
     * @param value A mapping of tags to assign to the resource.
     */
    @JvmName("qsjniwtcxuowwhmp")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

    /**
     * @param value Specifies the ISO8601 timespan specifying the minimum number of days the environment's events will be available for query.
     */
    @JvmName("iqdqsavmrjqxnmnl")
    public suspend fun warmStoreDataRetentionTime(`value`: Output) {
        this.warmStoreDataRetentionTime = value
    }

    /**
     * @param value A list of property ids for the Azure IoT Time Series Insights Gen2 Environment. Changing this forces a new resource to be created.
     */
    @JvmName("ivleyaorsqaehlua")
    public suspend fun idProperties(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.idProperties = mapped
    }

    /**
     * @param values A list of property ids for the Azure IoT Time Series Insights Gen2 Environment. Changing this forces a new resource to be created.
     */
    @JvmName("oqrcjfhttoqqxbmr")
    public suspend fun idProperties(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.idProperties = mapped
    }

    /**
     * @param value Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
     */
    @JvmName("vnomwdhqhoeqsnyx")
    public suspend fun location(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.location = mapped
    }

    /**
     * @param value Specifies the name of the Azure IoT Time Series Insights Gen2 Environment. Changing this forces a new resource to be created. Must be globally unique.
     */
    @JvmName("sjtdhnyqwerpfbqc")
    public suspend fun name(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value The name of the resource group in which to create the Azure IoT Time Series Insights Gen2 Environment. Changing this forces a new resource to be created.
     */
    @JvmName("hkguastqhhiltfcp")
    public suspend fun resourceGroupName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.resourceGroupName = mapped
    }

    /**
     * @param value Specifies the SKU Name for this IoT Time Series Insights Gen2 Environment. Currently it supports only `L1`. For gen2, capacity cannot be specified. Changing this forces a new resource to be created.
     */
    @JvmName("vhutiuaufohsreyr")
    public suspend fun skuName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.skuName = mapped
    }

    /**
     * @param value A `storage` block as defined below.
     */
    @JvmName("oadleykxergcirnx")
    public suspend fun storage(`value`: TimeSeriesInsightsGen2EnvironmentStorageArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.storage = mapped
    }

    /**
     * @param argument A `storage` block as defined below.
     */
    @JvmName("idicafbyawwnfksq")
    public suspend fun storage(argument: suspend TimeSeriesInsightsGen2EnvironmentStorageArgsBuilder.() -> Unit) {
        val toBeMapped = TimeSeriesInsightsGen2EnvironmentStorageArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.storage = mapped
    }

    /**
     * @param value A mapping of tags to assign to the resource.
     */
    @JvmName("thnyoorwcskmwinn")
    public suspend fun tags(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param values A mapping of tags to assign to the resource.
     */
    @JvmName("gaerbewwkswfsrmf")
    public fun tags(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param value Specifies the ISO8601 timespan specifying the minimum number of days the environment's events will be available for query.
     */
    @JvmName("tyrbxiwnpwppmpky")
    public suspend fun warmStoreDataRetentionTime(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.warmStoreDataRetentionTime = mapped
    }

    internal fun build(): TimeSeriesInsightsGen2EnvironmentArgs =
        TimeSeriesInsightsGen2EnvironmentArgs(
            idProperties = idProperties,
            location = location,
            name = name,
            resourceGroupName = resourceGroupName,
            skuName = skuName,
            storage = storage,
            tags = tags,
            warmStoreDataRetentionTime = warmStoreDataRetentionTime,
        )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy