Class Cache
Manages a Redis Cache.
Default Redis Configuration Values
| Redis Value | Basic | Standard | Premium |
|---|---|---|---|
| enable_authentication | true | true | true |
| maxmemory_reserved | 2 | 50 | 200 |
| maxfragmentationmemory_reserved | 2 | 50 | 200 |
| maxmemory_delta | 2 | 50 | 200 |
| maxmemory_policy | volatile-lru | volatile-lru | volatile-lru |
NOTE: The
maxmemory_reserved,maxmemory_deltaandmaxfragmentationmemory-reservedsettings are only available for Standard and Premium caches. More details are available in the Relevant Links section below._
A patch_schedule block supports the following:
day_of_week(Required) the Weekday name - possible values includeMonday,Tuesday,Wednesdayetc.start_hour_utc- (Optional) the Start Hour for maintenance in UTC - possible values range from0 - 23.
Note: The Patch Window lasts for
5hours from thestart_hour_utc.
Relevant Links
Inherited Members
Namespace: Pulumi.Azure.Redis
Assembly: Pulumi.Azure.dll
Syntax
public class Cache : CustomResource
Constructors
View SourceCache(String, CacheArgs, CustomResourceOptions)
Create a Cache resource with the given unique name, arguments, and options.
Declaration
public Cache(string name, CacheArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| CacheArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceCapacity
The size of the Redis cache to deploy. Valid values for a SKU family of C (Basic/Standard) are 0, 1, 2, 3, 4, 5, 6, and for P (Premium) family are 1, 2, 3, 4.
Declaration
public Output<int> Capacity { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Int32> |
EnableNonSslPort
Enable the non-SSL port (6379) - disabled by default.
Declaration
public Output<bool?> EnableNonSslPort { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Nullable<System.Boolean>> |
Family
The SKU family/pricing group to use. Valid values are C (for Basic/Standard SKU family) and P (for Premium)
Declaration
public Output<string> Family { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Hostname
The Hostname of the Redis Instance
Declaration
public Output<string> Hostname { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Location
The location of the resource group.
Declaration
public Output<string> Location { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
MinimumTlsVersion
The minimum TLS version. Defaults to 1.0.
Declaration
public Output<string> MinimumTlsVersion { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Name
The name of the Redis instance. Changing this forces a new resource to be created.
Declaration
public Output<string> Name { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
PatchSchedules
A list of patch_schedule blocks as defined below - only available for Premium SKU's.
Declaration
public Output<ImmutableArray<CachePatchSchedule>> PatchSchedules { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Collections.Immutable.ImmutableArray<CachePatchSchedule>> |
Port
The non-SSL Port of the Redis Instance
Declaration
public Output<int> Port { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Int32> |
PrimaryAccessKey
The Primary Access Key for the Redis Instance
Declaration
public Output<string> PrimaryAccessKey { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
PrimaryConnectionString
The primary connection string of the Redis Instance.
Declaration
public Output<string> PrimaryConnectionString { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
PrivateStaticIpAddress
The Static IP Address to assign to the Redis Cache when hosted inside the Virtual Network. Changing this forces a new resource to be created.
Declaration
public Output<string> PrivateStaticIpAddress { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
RedisConfiguration
A redis_configuration as defined below - with some limitations by SKU - defaults/details are shown below.
Declaration
public Output<CacheRedisConfiguration> RedisConfiguration { get; }
Property Value
| Type | Description |
|---|---|
| Output<CacheRedisConfiguration> |
ResourceGroupName
The name of the resource group in which to create the Redis instance.
Declaration
public Output<string> ResourceGroupName { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
SecondaryAccessKey
The Secondary Access Key for the Redis Instance
Declaration
public Output<string> SecondaryAccessKey { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
SecondaryConnectionString
The secondary connection string of the Redis Instance.
Declaration
public Output<string> SecondaryConnectionString { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
ShardCount
Only available when using the Premium SKU The number of Shards to create on the Redis Cluster.
Declaration
public Output<int?> ShardCount { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Nullable<System.Int32>> |
SkuName
The SKU of Redis to use. Possible values are Basic, Standard and Premium.
Declaration
public Output<string> SkuName { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
SslPort
The SSL Port of the Redis Instance
Declaration
public Output<int> SslPort { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Int32> |
SubnetId
Only available when using the Premium SKU The ID of the Subnet within which the Redis Cache should be deployed. This Subnet must only contain Azure Cache for Redis instances without any other type of resources. Changing this forces a new resource to be created.
Declaration
public Output<string> SubnetId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Tags
A mapping of tags to assign to the resource.
Declaration
public Output<ImmutableDictionary<string, string>> Tags { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Collections.Immutable.ImmutableDictionary<System.String, System.String>> |
Zones
A list of a single item of the Availability Zone which the Redis Cache should be allocated in.
Declaration
public Output<string> Zones { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, CacheState, CustomResourceOptions)
Get an existing Cache resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static Cache Get(string name, Input<string> id, CacheState state = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resulting resource. |
| Input<System.String> | id | The unique provider ID of the resource to lookup. |
| CacheState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| Cache |