# Amazon ElastiCache Construct Library

This module is part of the [AWS Cloud Development Kit](https://github.com/aws/aws-cdk) project.

```ts
import * as elasticache from 'aws-cdk-lib/aws-elasticache';
```

There are no official hand-written ([L2](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_lib)) constructs for this service yet. Here are some suggestions on how to proceed:

- Search [Construct Hub for ElastiCache construct libraries](https://constructs.dev/search?q=elasticache)
- Use the automatically generated [L1](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_l1_using) constructs, in the same way you would use [the CloudFormation AWS::ElastiCache resources](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/AWS_ElastiCache.html) directly.

There are no hand-written ([L2](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_lib)) constructs for this service yet.
However, you can still use the automatically generated [L1](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_l1_using) constructs, and use this service exactly as you would using CloudFormation directly.

For more information on the resources and properties available for this service, see the [CloudFormation documentation for AWS::ElastiCache](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/AWS_ElastiCache.html).

(Read the [CDK Contributing Guide](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) and submit an RFC if you are interested in contributing to this construct library.)

## Types

| Name | Kind | Summary |
| --- | --- | --- |
| [`CfnCacheCluster`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnCacheCluster) | Construct (L1) | The `AWS::ElastiCache::CacheCluster` type creates an Amazon ElastiCache cache cluster. |
| [`CfnGlobalReplicationGroup`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnGlobalReplicationGroup) | Construct (L1) | Consists of a primary cluster that accepts writes and an associated secondary cluster that resides in a different Amazon region. |
| [`CfnParameterGroup`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnParameterGroup) | Construct (L1) | The `AWS::ElastiCache::ParameterGroup` type creates a new cache parameter group. |
| [`CfnReplicationGroup`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnReplicationGroup) | Construct (L1) | The `AWS::ElastiCache::ReplicationGroup` resource creates an Amazon ElastiCache (Valkey or Redis OSS) replication group. |
| [`CfnSecurityGroup`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnSecurityGroup) | Construct (L1) | The `AWS::ElastiCache::SecurityGroup` resource creates a cache security group. |
| [`CfnSecurityGroupIngress`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnSecurityGroupIngress) | Construct (L1) | The AWS::ElastiCache::SecurityGroupIngress type authorizes ingress to a cache security group from hosts in specified Amazon EC2 security groups. |
| [`CfnServerlessCache`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnServerlessCache) | Construct (L1) | The resource representing a serverless cache. |
| [`CfnServerlessCacheSnapshot`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnServerlessCacheSnapshot) | Construct (L1) | Resource Type definition for AWS::ElastiCache::ServerlessCacheSnapshot. |
| [`CfnSnapshot`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnSnapshot) | Construct (L1) | Represents a copy of an entire cluster or replication group as of the time when the snapshot was taken. |
| [`CfnSubnetGroup`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnSubnetGroup) | Construct (L1) | Creates a cache subnet group. |
| [`CfnUser`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnUser) | Construct (L1) | For Valkey 7.2 and onwards, or Redis OSS engine version 6.0 and onwards: Creates user. For more information, see [Using Role Based Access Control (RBAC)](https://docs.aws.amazon.com/AmazonElastiCache/latest/dg/Clusters.RBAC.html) . |
| [`CfnUserGroup`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnUserGroup) | Construct (L1) | For Valkey 7.2 and onwards, or Redis OSS 6.0 and onwards: Creates a user group. For more information, see [Using Role Based Access Control (RBAC)](https://docs.aws.amazon.com/AmazonElastiCache/latest/dg/Clusters.RBAC.html). |
| [`CfnCacheCluster.CloudWatchLogsDestinationDetailsProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnCacheCluster.CloudWatchLogsDestinationDetailsProperty) | Struct | Configuration details of a CloudWatch Logs destination. |
| [`CfnCacheCluster.DestinationDetailsProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnCacheCluster.DestinationDetailsProperty) | Struct | Configuration details of either a CloudWatch Logs destination or Kinesis Data Firehose destination. |
| [`CfnCacheCluster.EndpointProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnCacheCluster.EndpointProperty) | Struct |  |
| [`CfnCacheCluster.KinesisFirehoseDestinationDetailsProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnCacheCluster.KinesisFirehoseDestinationDetailsProperty) | Struct | The configuration details of the Kinesis Data Firehose destination. |
| [`CfnCacheCluster.LogDeliveryConfigurationRequestProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnCacheCluster.LogDeliveryConfigurationRequestProperty) | Struct | Specifies the destination, format and type of the logs. |
| [`CfnCacheClusterProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnCacheClusterProps) | Struct | Properties for defining a `CfnCacheCluster`. |
| [`CfnGlobalReplicationGroup.GlobalReplicationGroupMemberProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnGlobalReplicationGroup.GlobalReplicationGroupMemberProperty) | Struct | A member of a Global datastore. |
| [`CfnGlobalReplicationGroup.RegionalConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnGlobalReplicationGroup.RegionalConfigurationProperty) | Struct | A list of the replication groups. |
| [`CfnGlobalReplicationGroup.ReshardingConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnGlobalReplicationGroup.ReshardingConfigurationProperty) | Struct | A list of `PreferredAvailabilityZones` objects that specifies the configuration of a node group in the resharded cluster. |
| [`CfnGlobalReplicationGroupProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnGlobalReplicationGroupProps) | Struct | Properties for defining a `CfnGlobalReplicationGroup`. |
| [`CfnParameterGroupProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnParameterGroupProps) | Struct | Properties for defining a `CfnParameterGroup`. |
| [`CfnReplicationGroup.CloudWatchLogsDestinationDetailsProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnReplicationGroup.CloudWatchLogsDestinationDetailsProperty) | Struct | The configuration details of the CloudWatch Logs destination. |
| [`CfnReplicationGroup.DestinationDetailsProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnReplicationGroup.DestinationDetailsProperty) | Struct | Configuration details of either a CloudWatch Logs destination or Kinesis Data Firehose destination. |
| [`CfnReplicationGroup.EndpointProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnReplicationGroup.EndpointProperty) | Struct |  |
| [`CfnReplicationGroup.KinesisFirehoseDestinationDetailsProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnReplicationGroup.KinesisFirehoseDestinationDetailsProperty) | Struct | The configuration details of the Kinesis Data Firehose destination. |
| [`CfnReplicationGroup.LogDeliveryConfigurationRequestProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnReplicationGroup.LogDeliveryConfigurationRequestProperty) | Struct | Specifies the destination, format and type of the logs. |
| [`CfnReplicationGroup.NodeGroupConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnReplicationGroup.NodeGroupConfigurationProperty) | Struct | `NodeGroupConfiguration` is a property of the `AWS::ElastiCache::ReplicationGroup` resource that configures an Amazon ElastiCache (ElastiCache) Valkey or Redis OSS cluster node group. |
| [`CfnReplicationGroup.ReadEndPointProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnReplicationGroup.ReadEndPointProperty) | Struct |  |
| [`CfnReplicationGroupProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnReplicationGroupProps) | Struct | Properties for defining a `CfnReplicationGroup`. |
| [`CfnSecurityGroupIngressProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnSecurityGroupIngressProps) | Struct | Properties for defining a `CfnSecurityGroupIngress`. |
| [`CfnSecurityGroupProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnSecurityGroupProps) | Struct | Properties for defining a `CfnSecurityGroup`. |
| [`CfnServerlessCache.CacheUsageLimitsProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnServerlessCache.CacheUsageLimitsProperty) | Struct | The usage limits for storage and ElastiCache Processing Units for the cache. |
| [`CfnServerlessCache.DataStorageProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnServerlessCache.DataStorageProperty) | Struct | The data storage limit. |
| [`CfnServerlessCache.ECPUPerSecondProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnServerlessCache.ECPUPerSecondProperty) | Struct | The configuration for the number of ElastiCache Processing Units (ECPU) the cache can consume per second. |
| [`CfnServerlessCache.EndpointProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnServerlessCache.EndpointProperty) | Struct | Represents the information required for client programs to connect to a cache node. |
| [`CfnServerlessCacheProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnServerlessCacheProps) | Struct | Properties for defining a `CfnServerlessCache`. |
| [`CfnServerlessCacheSnapshot.ServerlessCacheConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnServerlessCacheSnapshot.ServerlessCacheConfigurationProperty) | Struct |  |
| [`CfnServerlessCacheSnapshotProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnServerlessCacheSnapshotProps) | Struct | Properties for defining a `CfnServerlessCacheSnapshot`. |
| [`CfnSnapshot.NodeSnapshotProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnSnapshot.NodeSnapshotProperty) | Struct |  |
| [`CfnSnapshotProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnSnapshotProps) | Struct | Properties for defining a `CfnSnapshot`. |
| [`CfnSubnetGroupProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnSubnetGroupProps) | Struct | Properties for defining a `CfnSubnetGroup`. |
| [`CfnUser.AuthenticationModeProperty`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnUser.AuthenticationModeProperty) | Struct | Specifies the authentication mode to use. |
| [`CfnUserGroupProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnUserGroupProps) | Struct | Properties for defining a `CfnUserGroup`. |
| [`CfnUserProps`](/v2/docs/aws-cdk-lib.aws_elasticache.CfnUserProps) | Struct | Properties for defining a `CfnUser`. |
