Skip to content
v2.274.0

CfnSubnetGroupProps Struct ​

Properties for defining a CfnSubnetGroup.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_elasticache as elasticache } from 'aws-cdk-lib';
const cfnSubnetGroupProps: elasticache.CfnSubnetGroupProps = {
  description: 'description',
  subnetIds: ['subnetIds'],

  // the properties below are optional
  cacheSubnetGroupName: 'cacheSubnetGroupName',
  tags: [{
    key: 'key',
    value: 'value',
  }],
};

Properties ​

cacheSubnetGroupNameoptionalstringcache_subnet_group_nameoptionalstrcacheSubnetGroupNameoptionalStringCacheSubnetGroupNameoptionalstringCacheSubnetGroupNameoptional*string#
The name for the cache subnet group. This value is stored as a lowercase string.

Constraints: Must contain no more than 255 alphanumeric characters or hyphens.

Example: mysubnetgroup

descriptionstringdescriptionstrdescriptionStringDescriptionstringDescription*stringrequired#
The description for the cache subnet group.
subnetIdsstring | ISubnetRef[]subnet_idstyping.List[typing.Union[str, ISubnetRef]]subnetIdsList<String>SubnetIdsstring[]SubnetIds*[]interface{}required#
The EC2 subnet IDs for the cache subnet group.
tagsoptionalCfnTag[]tagsoptionaltyping.List[CfnTag]tagsoptionalList<CfnTag>TagsoptionalCfnTag[]Tagsoptional*[]CfnTag#
A tag that can be added to an ElastiCache subnet group.

Tags are composed of a Key/Value pair. You can use tags to categorize and track all your subnet groups. A tag with a null Value is permitted.