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

com.pulumi.azurenative.cache.kotlin.RedisArgs.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: 2.82.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azurenative.cache.kotlin

import com.pulumi.azurenative.cache.RedisArgs.builder
import com.pulumi.azurenative.cache.kotlin.enums.PublicNetworkAccess
import com.pulumi.azurenative.cache.kotlin.enums.TlsVersion
import com.pulumi.azurenative.cache.kotlin.inputs.ManagedServiceIdentityArgs
import com.pulumi.azurenative.cache.kotlin.inputs.ManagedServiceIdentityArgsBuilder
import com.pulumi.azurenative.cache.kotlin.inputs.RedisCommonPropertiesRedisConfigurationArgs
import com.pulumi.azurenative.cache.kotlin.inputs.RedisCommonPropertiesRedisConfigurationArgsBuilder
import com.pulumi.azurenative.cache.kotlin.inputs.SkuArgs
import com.pulumi.azurenative.cache.kotlin.inputs.SkuArgsBuilder
import com.pulumi.core.Either
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.Boolean
import kotlin.Int
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import kotlin.jvm.JvmName

/**
 * A single Redis item in List or Get Operation.
 * Azure REST API version: 2023-04-01. Prior API version in Azure Native 1.x: 2020-06-01.
 * Other available API versions: 2015-08-01, 2017-02-01, 2019-07-01, 2020-06-01, 2023-05-01-preview, 2023-08-01, 2024-03-01, 2024-04-01-preview.
 * ## Example Usage
 * ### RedisCacheCreate
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using AzureNative = Pulumi.AzureNative;
 * return await Deployment.RunAsync(() =>
 * {
 *     var redis = new AzureNative.Cache.Redis("redis", new()
 *     {
 *         EnableNonSslPort = true,
 *         Location = "West US",
 *         MinimumTlsVersion = AzureNative.Cache.TlsVersion.TlsVersion_1_2,
 *         Name = "cache1",
 *         RedisConfiguration = new AzureNative.Cache.Inputs.RedisCommonPropertiesRedisConfigurationArgs
 *         {
 *             MaxmemoryPolicy = "allkeys-lru",
 *         },
 *         RedisVersion = "4",
 *         ReplicasPerPrimary = 2,
 *         ResourceGroupName = "rg1",
 *         ShardCount = 2,
 *         Sku = new AzureNative.Cache.Inputs.SkuArgs
 *         {
 *             Capacity = 1,
 *             Family = AzureNative.Cache.SkuFamily.P,
 *             Name = "Premium",
 *         },
 *         StaticIP = "192.168.0.5",
 *         SubnetId = "/subscriptions/subid/resourceGroups/rg2/providers/Microsoft.Network/virtualNetworks/network1/subnets/subnet1",
 *         Zones = new[]
 *         {
 *             "1",
 *         },
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	cache "github.com/pulumi/pulumi-azure-native-sdk/cache/v2"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := cache.NewRedis(ctx, "redis", &cache.RedisArgs{
 * 			EnableNonSslPort:  pulumi.Bool(true),
 * 			Location:          pulumi.String("West US"),
 * 			MinimumTlsVersion: pulumi.String(cache.TlsVersion_1_2),
 * 			Name:              pulumi.String("cache1"),
 * 			RedisConfiguration: &cache.RedisCommonPropertiesRedisConfigurationArgs{
 * 				MaxmemoryPolicy: pulumi.String("allkeys-lru"),
 * 			},
 * 			RedisVersion:       pulumi.String("4"),
 * 			ReplicasPerPrimary: pulumi.Int(2),
 * 			ResourceGroupName:  pulumi.String("rg1"),
 * 			ShardCount:         pulumi.Int(2),
 * 			Sku: &cache.SkuArgs{
 * 				Capacity: pulumi.Int(1),
 * 				Family:   pulumi.String(cache.SkuFamilyP),
 * 				Name:     pulumi.String("Premium"),
 * 			},
 * 			StaticIP: pulumi.String("192.168.0.5"),
 * 			SubnetId: pulumi.String("/subscriptions/subid/resourceGroups/rg2/providers/Microsoft.Network/virtualNetworks/network1/subnets/subnet1"),
 * 			Zones: pulumi.StringArray{
 * 				pulumi.String("1"),
 * 			},
 * 		})
 * 		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.azurenative.cache.Redis;
 * import com.pulumi.azurenative.cache.RedisArgs;
 * import com.pulumi.azurenative.cache.inputs.RedisCommonPropertiesRedisConfigurationArgs;
 * import com.pulumi.azurenative.cache.inputs.SkuArgs;
 * 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 redis = new Redis("redis", RedisArgs.builder()
 *             .enableNonSslPort(true)
 *             .location("West US")
 *             .minimumTlsVersion("1.2")
 *             .name("cache1")
 *             .redisConfiguration(RedisCommonPropertiesRedisConfigurationArgs.builder()
 *                 .maxmemoryPolicy("allkeys-lru")
 *                 .build())
 *             .redisVersion("4")
 *             .replicasPerPrimary(2)
 *             .resourceGroupName("rg1")
 *             .shardCount(2)
 *             .sku(SkuArgs.builder()
 *                 .capacity(1)
 *                 .family("P")
 *                 .name("Premium")
 *                 .build())
 *             .staticIP("192.168.0.5")
 *             .subnetId("/subscriptions/subid/resourceGroups/rg2/providers/Microsoft.Network/virtualNetworks/network1/subnets/subnet1")
 *             .zones("1")
 *             .build());
 *     }
 * }
 * ```
 * ### RedisCacheCreateDefaultVersion
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using AzureNative = Pulumi.AzureNative;
 * return await Deployment.RunAsync(() =>
 * {
 *     var redis = new AzureNative.Cache.Redis("redis", new()
 *     {
 *         EnableNonSslPort = true,
 *         Location = "West US",
 *         MinimumTlsVersion = AzureNative.Cache.TlsVersion.TlsVersion_1_2,
 *         Name = "cache1",
 *         RedisConfiguration = new AzureNative.Cache.Inputs.RedisCommonPropertiesRedisConfigurationArgs
 *         {
 *             MaxmemoryPolicy = "allkeys-lru",
 *         },
 *         ReplicasPerPrimary = 2,
 *         ResourceGroupName = "rg1",
 *         ShardCount = 2,
 *         Sku = new AzureNative.Cache.Inputs.SkuArgs
 *         {
 *             Capacity = 1,
 *             Family = AzureNative.Cache.SkuFamily.P,
 *             Name = "Premium",
 *         },
 *         StaticIP = "192.168.0.5",
 *         SubnetId = "/subscriptions/subid/resourceGroups/rg2/providers/Microsoft.Network/virtualNetworks/network1/subnets/subnet1",
 *         Zones = new[]
 *         {
 *             "1",
 *         },
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	cache "github.com/pulumi/pulumi-azure-native-sdk/cache/v2"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := cache.NewRedis(ctx, "redis", &cache.RedisArgs{
 * 			EnableNonSslPort:  pulumi.Bool(true),
 * 			Location:          pulumi.String("West US"),
 * 			MinimumTlsVersion: pulumi.String(cache.TlsVersion_1_2),
 * 			Name:              pulumi.String("cache1"),
 * 			RedisConfiguration: &cache.RedisCommonPropertiesRedisConfigurationArgs{
 * 				MaxmemoryPolicy: pulumi.String("allkeys-lru"),
 * 			},
 * 			ReplicasPerPrimary: pulumi.Int(2),
 * 			ResourceGroupName:  pulumi.String("rg1"),
 * 			ShardCount:         pulumi.Int(2),
 * 			Sku: &cache.SkuArgs{
 * 				Capacity: pulumi.Int(1),
 * 				Family:   pulumi.String(cache.SkuFamilyP),
 * 				Name:     pulumi.String("Premium"),
 * 			},
 * 			StaticIP: pulumi.String("192.168.0.5"),
 * 			SubnetId: pulumi.String("/subscriptions/subid/resourceGroups/rg2/providers/Microsoft.Network/virtualNetworks/network1/subnets/subnet1"),
 * 			Zones: pulumi.StringArray{
 * 				pulumi.String("1"),
 * 			},
 * 		})
 * 		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.azurenative.cache.Redis;
 * import com.pulumi.azurenative.cache.RedisArgs;
 * import com.pulumi.azurenative.cache.inputs.RedisCommonPropertiesRedisConfigurationArgs;
 * import com.pulumi.azurenative.cache.inputs.SkuArgs;
 * 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 redis = new Redis("redis", RedisArgs.builder()
 *             .enableNonSslPort(true)
 *             .location("West US")
 *             .minimumTlsVersion("1.2")
 *             .name("cache1")
 *             .redisConfiguration(RedisCommonPropertiesRedisConfigurationArgs.builder()
 *                 .maxmemoryPolicy("allkeys-lru")
 *                 .build())
 *             .replicasPerPrimary(2)
 *             .resourceGroupName("rg1")
 *             .shardCount(2)
 *             .sku(SkuArgs.builder()
 *                 .capacity(1)
 *                 .family("P")
 *                 .name("Premium")
 *                 .build())
 *             .staticIP("192.168.0.5")
 *             .subnetId("/subscriptions/subid/resourceGroups/rg2/providers/Microsoft.Network/virtualNetworks/network1/subnets/subnet1")
 *             .zones("1")
 *             .build());
 *     }
 * }
 * ```
 * ### RedisCacheCreateLatestVersion
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using AzureNative = Pulumi.AzureNative;
 * return await Deployment.RunAsync(() =>
 * {
 *     var redis = new AzureNative.Cache.Redis("redis", new()
 *     {
 *         EnableNonSslPort = true,
 *         Location = "West US",
 *         MinimumTlsVersion = AzureNative.Cache.TlsVersion.TlsVersion_1_2,
 *         Name = "cache1",
 *         RedisConfiguration = new AzureNative.Cache.Inputs.RedisCommonPropertiesRedisConfigurationArgs
 *         {
 *             MaxmemoryPolicy = "allkeys-lru",
 *         },
 *         RedisVersion = "Latest",
 *         ReplicasPerPrimary = 2,
 *         ResourceGroupName = "rg1",
 *         ShardCount = 2,
 *         Sku = new AzureNative.Cache.Inputs.SkuArgs
 *         {
 *             Capacity = 1,
 *             Family = AzureNative.Cache.SkuFamily.P,
 *             Name = "Premium",
 *         },
 *         StaticIP = "192.168.0.5",
 *         SubnetId = "/subscriptions/subid/resourceGroups/rg2/providers/Microsoft.Network/virtualNetworks/network1/subnets/subnet1",
 *         Zones = new[]
 *         {
 *             "1",
 *         },
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	cache "github.com/pulumi/pulumi-azure-native-sdk/cache/v2"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := cache.NewRedis(ctx, "redis", &cache.RedisArgs{
 * 			EnableNonSslPort:  pulumi.Bool(true),
 * 			Location:          pulumi.String("West US"),
 * 			MinimumTlsVersion: pulumi.String(cache.TlsVersion_1_2),
 * 			Name:              pulumi.String("cache1"),
 * 			RedisConfiguration: &cache.RedisCommonPropertiesRedisConfigurationArgs{
 * 				MaxmemoryPolicy: pulumi.String("allkeys-lru"),
 * 			},
 * 			RedisVersion:       pulumi.String("Latest"),
 * 			ReplicasPerPrimary: pulumi.Int(2),
 * 			ResourceGroupName:  pulumi.String("rg1"),
 * 			ShardCount:         pulumi.Int(2),
 * 			Sku: &cache.SkuArgs{
 * 				Capacity: pulumi.Int(1),
 * 				Family:   pulumi.String(cache.SkuFamilyP),
 * 				Name:     pulumi.String("Premium"),
 * 			},
 * 			StaticIP: pulumi.String("192.168.0.5"),
 * 			SubnetId: pulumi.String("/subscriptions/subid/resourceGroups/rg2/providers/Microsoft.Network/virtualNetworks/network1/subnets/subnet1"),
 * 			Zones: pulumi.StringArray{
 * 				pulumi.String("1"),
 * 			},
 * 		})
 * 		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.azurenative.cache.Redis;
 * import com.pulumi.azurenative.cache.RedisArgs;
 * import com.pulumi.azurenative.cache.inputs.RedisCommonPropertiesRedisConfigurationArgs;
 * import com.pulumi.azurenative.cache.inputs.SkuArgs;
 * 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 redis = new Redis("redis", RedisArgs.builder()
 *             .enableNonSslPort(true)
 *             .location("West US")
 *             .minimumTlsVersion("1.2")
 *             .name("cache1")
 *             .redisConfiguration(RedisCommonPropertiesRedisConfigurationArgs.builder()
 *                 .maxmemoryPolicy("allkeys-lru")
 *                 .build())
 *             .redisVersion("Latest")
 *             .replicasPerPrimary(2)
 *             .resourceGroupName("rg1")
 *             .shardCount(2)
 *             .sku(SkuArgs.builder()
 *                 .capacity(1)
 *                 .family("P")
 *                 .name("Premium")
 *                 .build())
 *             .staticIP("192.168.0.5")
 *             .subnetId("/subscriptions/subid/resourceGroups/rg2/providers/Microsoft.Network/virtualNetworks/network1/subnets/subnet1")
 *             .zones("1")
 *             .build());
 *     }
 * }
 * ```
 * ## Import
 * An existing resource can be imported using its type token, name, and identifier, e.g.
 * ```sh
 * $ pulumi import azure-native:cache:Redis cache1 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cache/redis/{name}
 * ```
 * @property enableNonSslPort Specifies whether the non-ssl Redis server port (6379) is enabled.
 * @property identity The identity of the resource.
 * @property location The geo-location where the resource lives
 * @property minimumTlsVersion Optional: requires clients to use a specified TLS version (or higher) to connect (e,g, '1.0', '1.1', '1.2')
 * @property name The name of the Redis cache.
 * @property publicNetworkAccess Whether or not public endpoint access is allowed for this cache.  Value is optional, but if passed in, must be 'Enabled' or 'Disabled'. If 'Disabled', private endpoints are the exclusive access method. Default value is 'Enabled'. Note: This setting is important for caches with private endpoints. It has *no effect* on caches that are joined to, or injected into, a virtual network subnet.
 * @property redisConfiguration All Redis Settings. Few possible keys: rdb-backup-enabled,rdb-storage-connection-string,rdb-backup-frequency,maxmemory-delta,maxmemory-policy,notify-keyspace-events,maxmemory-samples,slowlog-log-slower-than,slowlog-max-len,list-max-ziplist-entries,list-max-ziplist-value,hash-max-ziplist-entries,hash-max-ziplist-value,set-max-intset-entries,zset-max-ziplist-entries,zset-max-ziplist-value etc.
 * @property redisVersion Redis version. This should be in the form 'major[.minor]' (only 'major' is required) or the value 'latest' which refers to the latest stable Redis version that is available. Supported versions: 4.0, 6.0 (latest). Default value is 'latest'.
 * @property replicasPerMaster The number of replicas to be created per primary.
 * @property replicasPerPrimary The number of replicas to be created per primary.
 * @property resourceGroupName The name of the resource group.
 * @property shardCount The number of shards to be created on a Premium Cluster Cache.
 * @property sku The SKU of the Redis cache to deploy.
 * @property staticIP Static IP address. Optionally, may be specified when deploying a Redis cache inside an existing Azure Virtual Network; auto assigned by default.
 * @property subnetId The full resource ID of a subnet in a virtual network to deploy the Redis cache in. Example format: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/Microsoft.{Network|ClassicNetwork}/VirtualNetworks/vnet1/subnets/subnet1
 * @property tags Resource tags.
 * @property tenantSettings A dictionary of tenant settings
 * @property zones A list of availability zones denoting where the resource needs to come from.
 */
public data class RedisArgs(
    public val enableNonSslPort: Output? = null,
    public val identity: Output? = null,
    public val location: Output? = null,
    public val minimumTlsVersion: Output>? = null,
    public val name: Output? = null,
    public val publicNetworkAccess: Output>? = null,
    public val redisConfiguration: Output? = null,
    public val redisVersion: Output? = null,
    public val replicasPerMaster: Output? = null,
    public val replicasPerPrimary: Output? = null,
    public val resourceGroupName: Output? = null,
    public val shardCount: Output? = null,
    public val sku: Output? = null,
    public val staticIP: Output? = null,
    public val subnetId: Output? = null,
    public val tags: Output>? = null,
    public val tenantSettings: Output>? = null,
    public val zones: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.cache.RedisArgs =
        com.pulumi.azurenative.cache.RedisArgs.builder()
            .enableNonSslPort(enableNonSslPort?.applyValue({ args0 -> args0 }))
            .identity(identity?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .location(location?.applyValue({ args0 -> args0 }))
            .minimumTlsVersion(
                minimumTlsVersion?.applyValue({ args0 ->
                    args0.transform(
                        { args0 -> args0 },
                        { args0 -> args0.let({ args0 -> args0.toJava() }) },
                    )
                }),
            )
            .name(name?.applyValue({ args0 -> args0 }))
            .publicNetworkAccess(
                publicNetworkAccess?.applyValue({ args0 ->
                    args0.transform(
                        { args0 -> args0 },
                        { args0 -> args0.let({ args0 -> args0.toJava() }) },
                    )
                }),
            )
            .redisConfiguration(
                redisConfiguration?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .redisVersion(redisVersion?.applyValue({ args0 -> args0 }))
            .replicasPerMaster(replicasPerMaster?.applyValue({ args0 -> args0 }))
            .replicasPerPrimary(replicasPerPrimary?.applyValue({ args0 -> args0 }))
            .resourceGroupName(resourceGroupName?.applyValue({ args0 -> args0 }))
            .shardCount(shardCount?.applyValue({ args0 -> args0 }))
            .sku(sku?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .staticIP(staticIP?.applyValue({ args0 -> args0 }))
            .subnetId(subnetId?.applyValue({ args0 -> args0 }))
            .tags(tags?.applyValue({ args0 -> args0.map({ args0 -> args0.key.to(args0.value) }).toMap() }))
            .tenantSettings(
                tenantSettings?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            )
            .zones(zones?.applyValue({ args0 -> args0.map({ args0 -> args0 }) })).build()
}

/**
 * Builder for [RedisArgs].
 */
@PulumiTagMarker
public class RedisArgsBuilder internal constructor() {
    private var enableNonSslPort: Output? = null

    private var identity: Output? = null

    private var location: Output? = null

    private var minimumTlsVersion: Output>? = null

    private var name: Output? = null

    private var publicNetworkAccess: Output>? = null

    private var redisConfiguration: Output? = null

    private var redisVersion: Output? = null

    private var replicasPerMaster: Output? = null

    private var replicasPerPrimary: Output? = null

    private var resourceGroupName: Output? = null

    private var shardCount: Output? = null

    private var sku: Output? = null

    private var staticIP: Output? = null

    private var subnetId: Output? = null

    private var tags: Output>? = null

    private var tenantSettings: Output>? = null

    private var zones: Output>? = null

    /**
     * @param value Specifies whether the non-ssl Redis server port (6379) is enabled.
     */
    @JvmName("dohfwnpwflbanuuf")
    public suspend fun enableNonSslPort(`value`: Output) {
        this.enableNonSslPort = value
    }

    /**
     * @param value The identity of the resource.
     */
    @JvmName("teayvreccmsaphtl")
    public suspend fun identity(`value`: Output) {
        this.identity = value
    }

    /**
     * @param value The geo-location where the resource lives
     */
    @JvmName("lifdhtkndlympqkf")
    public suspend fun location(`value`: Output) {
        this.location = value
    }

    /**
     * @param value Optional: requires clients to use a specified TLS version (or higher) to connect (e,g, '1.0', '1.1', '1.2')
     */
    @JvmName("repvwehrffccnvxr")
    public suspend fun minimumTlsVersion(`value`: Output>) {
        this.minimumTlsVersion = value
    }

    /**
     * @param value The name of the Redis cache.
     */
    @JvmName("qeyeuebpwlyochrk")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value Whether or not public endpoint access is allowed for this cache.  Value is optional, but if passed in, must be 'Enabled' or 'Disabled'. If 'Disabled', private endpoints are the exclusive access method. Default value is 'Enabled'. Note: This setting is important for caches with private endpoints. It has *no effect* on caches that are joined to, or injected into, a virtual network subnet.
     */
    @JvmName("hvrxcoivmbuvtcnf")
    public suspend fun publicNetworkAccess(`value`: Output>) {
        this.publicNetworkAccess = value
    }

    /**
     * @param value All Redis Settings. Few possible keys: rdb-backup-enabled,rdb-storage-connection-string,rdb-backup-frequency,maxmemory-delta,maxmemory-policy,notify-keyspace-events,maxmemory-samples,slowlog-log-slower-than,slowlog-max-len,list-max-ziplist-entries,list-max-ziplist-value,hash-max-ziplist-entries,hash-max-ziplist-value,set-max-intset-entries,zset-max-ziplist-entries,zset-max-ziplist-value etc.
     */
    @JvmName("gnilqtuomewtivty")
    public suspend fun redisConfiguration(`value`: Output) {
        this.redisConfiguration = value
    }

    /**
     * @param value Redis version. This should be in the form 'major[.minor]' (only 'major' is required) or the value 'latest' which refers to the latest stable Redis version that is available. Supported versions: 4.0, 6.0 (latest). Default value is 'latest'.
     */
    @JvmName("xegierncfluobiim")
    public suspend fun redisVersion(`value`: Output) {
        this.redisVersion = value
    }

    /**
     * @param value The number of replicas to be created per primary.
     */
    @JvmName("rgmuxsmehggiovpf")
    public suspend fun replicasPerMaster(`value`: Output) {
        this.replicasPerMaster = value
    }

    /**
     * @param value The number of replicas to be created per primary.
     */
    @JvmName("jrbmloqjegwixnam")
    public suspend fun replicasPerPrimary(`value`: Output) {
        this.replicasPerPrimary = value
    }

    /**
     * @param value The name of the resource group.
     */
    @JvmName("jbxohtxbexgihlmg")
    public suspend fun resourceGroupName(`value`: Output) {
        this.resourceGroupName = value
    }

    /**
     * @param value The number of shards to be created on a Premium Cluster Cache.
     */
    @JvmName("vsjfvvvgsyxjkoee")
    public suspend fun shardCount(`value`: Output) {
        this.shardCount = value
    }

    /**
     * @param value The SKU of the Redis cache to deploy.
     */
    @JvmName("jpnwhvskvnpahxnh")
    public suspend fun sku(`value`: Output) {
        this.sku = value
    }

    /**
     * @param value Static IP address. Optionally, may be specified when deploying a Redis cache inside an existing Azure Virtual Network; auto assigned by default.
     */
    @JvmName("qoedfndxjsfrtbxp")
    public suspend fun staticIP(`value`: Output) {
        this.staticIP = value
    }

    /**
     * @param value The full resource ID of a subnet in a virtual network to deploy the Redis cache in. Example format: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/Microsoft.{Network|ClassicNetwork}/VirtualNetworks/vnet1/subnets/subnet1
     */
    @JvmName("vsijmufnngptgxww")
    public suspend fun subnetId(`value`: Output) {
        this.subnetId = value
    }

    /**
     * @param value Resource tags.
     */
    @JvmName("rknckowknhtswjgj")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

    /**
     * @param value A dictionary of tenant settings
     */
    @JvmName("yidnisuyfsjmcbcb")
    public suspend fun tenantSettings(`value`: Output>) {
        this.tenantSettings = value
    }

    /**
     * @param value A list of availability zones denoting where the resource needs to come from.
     */
    @JvmName("ydrjbbekvcppldux")
    public suspend fun zones(`value`: Output>) {
        this.zones = value
    }

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

    /**
     * @param values A list of availability zones denoting where the resource needs to come from.
     */
    @JvmName("dqideatesfvqpgqg")
    public suspend fun zones(values: List>) {
        this.zones = Output.all(values)
    }

    /**
     * @param value Specifies whether the non-ssl Redis server port (6379) is enabled.
     */
    @JvmName("opjnnhdjlrfxrxyp")
    public suspend fun enableNonSslPort(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.enableNonSslPort = mapped
    }

    /**
     * @param value The identity of the resource.
     */
    @JvmName("joephqexhktguoif")
    public suspend fun identity(`value`: ManagedServiceIdentityArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.identity = mapped
    }

    /**
     * @param argument The identity of the resource.
     */
    @JvmName("ehvkyyacfismvupb")
    public suspend fun identity(argument: suspend ManagedServiceIdentityArgsBuilder.() -> Unit) {
        val toBeMapped = ManagedServiceIdentityArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.identity = mapped
    }

    /**
     * @param value The geo-location where the resource lives
     */
    @JvmName("xgxesqnqlnfflrka")
    public suspend fun location(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.location = mapped
    }

    /**
     * @param value Optional: requires clients to use a specified TLS version (or higher) to connect (e,g, '1.0', '1.1', '1.2')
     */
    @JvmName("ihswdxigwwtawuqv")
    public suspend fun minimumTlsVersion(`value`: Either?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.minimumTlsVersion = mapped
    }

    /**
     * @param value Optional: requires clients to use a specified TLS version (or higher) to connect (e,g, '1.0', '1.1', '1.2')
     */
    @JvmName("mmgqfibapmnhhifj")
    public fun minimumTlsVersion(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.minimumTlsVersion = mapped
    }

    /**
     * @param value Optional: requires clients to use a specified TLS version (or higher) to connect (e,g, '1.0', '1.1', '1.2')
     */
    @JvmName("wclotqahbvdwcgxm")
    public fun minimumTlsVersion(`value`: TlsVersion) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.minimumTlsVersion = mapped
    }

    /**
     * @param value The name of the Redis cache.
     */
    @JvmName("yxjpelmuuldbliov")
    public suspend fun name(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value Whether or not public endpoint access is allowed for this cache.  Value is optional, but if passed in, must be 'Enabled' or 'Disabled'. If 'Disabled', private endpoints are the exclusive access method. Default value is 'Enabled'. Note: This setting is important for caches with private endpoints. It has *no effect* on caches that are joined to, or injected into, a virtual network subnet.
     */
    @JvmName("sqaajobrtxffmjyd")
    public suspend fun publicNetworkAccess(`value`: Either?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.publicNetworkAccess = mapped
    }

    /**
     * @param value Whether or not public endpoint access is allowed for this cache.  Value is optional, but if passed in, must be 'Enabled' or 'Disabled'. If 'Disabled', private endpoints are the exclusive access method. Default value is 'Enabled'. Note: This setting is important for caches with private endpoints. It has *no effect* on caches that are joined to, or injected into, a virtual network subnet.
     */
    @JvmName("hfjfgbethqeysecw")
    public fun publicNetworkAccess(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.publicNetworkAccess = mapped
    }

    /**
     * @param value Whether or not public endpoint access is allowed for this cache.  Value is optional, but if passed in, must be 'Enabled' or 'Disabled'. If 'Disabled', private endpoints are the exclusive access method. Default value is 'Enabled'. Note: This setting is important for caches with private endpoints. It has *no effect* on caches that are joined to, or injected into, a virtual network subnet.
     */
    @JvmName("soykgnghesowofib")
    public fun publicNetworkAccess(`value`: PublicNetworkAccess) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.publicNetworkAccess = mapped
    }

    /**
     * @param value All Redis Settings. Few possible keys: rdb-backup-enabled,rdb-storage-connection-string,rdb-backup-frequency,maxmemory-delta,maxmemory-policy,notify-keyspace-events,maxmemory-samples,slowlog-log-slower-than,slowlog-max-len,list-max-ziplist-entries,list-max-ziplist-value,hash-max-ziplist-entries,hash-max-ziplist-value,set-max-intset-entries,zset-max-ziplist-entries,zset-max-ziplist-value etc.
     */
    @JvmName("fngvgtgnimapjwrb")
    public suspend fun redisConfiguration(`value`: RedisCommonPropertiesRedisConfigurationArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.redisConfiguration = mapped
    }

    /**
     * @param argument All Redis Settings. Few possible keys: rdb-backup-enabled,rdb-storage-connection-string,rdb-backup-frequency,maxmemory-delta,maxmemory-policy,notify-keyspace-events,maxmemory-samples,slowlog-log-slower-than,slowlog-max-len,list-max-ziplist-entries,list-max-ziplist-value,hash-max-ziplist-entries,hash-max-ziplist-value,set-max-intset-entries,zset-max-ziplist-entries,zset-max-ziplist-value etc.
     */
    @JvmName("dxhfusyqdorqnxkd")
    public suspend fun redisConfiguration(argument: suspend RedisCommonPropertiesRedisConfigurationArgsBuilder.() -> Unit) {
        val toBeMapped = RedisCommonPropertiesRedisConfigurationArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.redisConfiguration = mapped
    }

    /**
     * @param value Redis version. This should be in the form 'major[.minor]' (only 'major' is required) or the value 'latest' which refers to the latest stable Redis version that is available. Supported versions: 4.0, 6.0 (latest). Default value is 'latest'.
     */
    @JvmName("pexroskowmretvpc")
    public suspend fun redisVersion(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.redisVersion = mapped
    }

    /**
     * @param value The number of replicas to be created per primary.
     */
    @JvmName("ieaacphaieecyunw")
    public suspend fun replicasPerMaster(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.replicasPerMaster = mapped
    }

    /**
     * @param value The number of replicas to be created per primary.
     */
    @JvmName("yshwlpwqjnuwwglh")
    public suspend fun replicasPerPrimary(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.replicasPerPrimary = mapped
    }

    /**
     * @param value The name of the resource group.
     */
    @JvmName("rilsgjutndamehbm")
    public suspend fun resourceGroupName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.resourceGroupName = mapped
    }

    /**
     * @param value The number of shards to be created on a Premium Cluster Cache.
     */
    @JvmName("ahceukinjrwlnxpd")
    public suspend fun shardCount(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.shardCount = mapped
    }

    /**
     * @param value The SKU of the Redis cache to deploy.
     */
    @JvmName("bnloewcmyiibmgtt")
    public suspend fun sku(`value`: SkuArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.sku = mapped
    }

    /**
     * @param argument The SKU of the Redis cache to deploy.
     */
    @JvmName("npxfqdqeqnepfpcp")
    public suspend fun sku(argument: suspend SkuArgsBuilder.() -> Unit) {
        val toBeMapped = SkuArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.sku = mapped
    }

    /**
     * @param value Static IP address. Optionally, may be specified when deploying a Redis cache inside an existing Azure Virtual Network; auto assigned by default.
     */
    @JvmName("jmhyrpwjeafobwaa")
    public suspend fun staticIP(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.staticIP = mapped
    }

    /**
     * @param value The full resource ID of a subnet in a virtual network to deploy the Redis cache in. Example format: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/Microsoft.{Network|ClassicNetwork}/VirtualNetworks/vnet1/subnets/subnet1
     */
    @JvmName("iyktrkxjhmbvsabs")
    public suspend fun subnetId(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.subnetId = mapped
    }

    /**
     * @param value Resource tags.
     */
    @JvmName("rjwuwypaswdwywur")
    public suspend fun tags(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param values Resource tags.
     */
    @JvmName("lupivsmrkmmanpxo")
    public fun tags(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param value A dictionary of tenant settings
     */
    @JvmName("kosfqohpiiulpjvo")
    public suspend fun tenantSettings(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tenantSettings = mapped
    }

    /**
     * @param values A dictionary of tenant settings
     */
    @JvmName("xceomyghkbeetwdh")
    public fun tenantSettings(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tenantSettings = mapped
    }

    /**
     * @param value A list of availability zones denoting where the resource needs to come from.
     */
    @JvmName("wlvkltoekesfnxje")
    public suspend fun zones(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.zones = mapped
    }

    /**
     * @param values A list of availability zones denoting where the resource needs to come from.
     */
    @JvmName("ihpcvilomolgwttk")
    public suspend fun zones(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.zones = mapped
    }

    internal fun build(): RedisArgs = RedisArgs(
        enableNonSslPort = enableNonSslPort,
        identity = identity,
        location = location,
        minimumTlsVersion = minimumTlsVersion,
        name = name,
        publicNetworkAccess = publicNetworkAccess,
        redisConfiguration = redisConfiguration,
        redisVersion = redisVersion,
        replicasPerMaster = replicasPerMaster,
        replicasPerPrimary = replicasPerPrimary,
        resourceGroupName = resourceGroupName,
        shardCount = shardCount,
        sku = sku,
        staticIP = staticIP,
        subnetId = subnetId,
        tags = tags,
        tenantSettings = tenantSettings,
        zones = zones,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy