Class CfnSnapshot
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.elasticache.CfnSnapshot
- All Implemented Interfaces:
IInspectable,ISnapshotRef,IEnvironmentAware,ITaggableV2,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.140.0 (build 79fd58c)",
date="2026-10-08T16:59:54.491Z")
@Stability(Stable)
public class CfnSnapshot
extends CfnResource
implements IInspectable, ISnapshotRef, ITaggableV2
Represents a copy of an entire cluster or replication group as of the time when the snapshot was taken.
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.elasticache.*;
CfnSnapshot cfnSnapshot = CfnSnapshot.Builder.create(this, "MyCfnSnapshot")
.snapshotName("snapshotName")
// the properties below are optional
.cacheClusterId("cacheClusterId")
.kmsKeyId("kmsKeyId")
.replicationGroupId("replicationGroupId")
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA fluent builder forCfnSnapshot.static interfaceExample:Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.interfaces.elasticache.ISnapshotRef
ISnapshotRef.Jsii$Default, ISnapshotRef.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.ITaggableV2
ITaggableV2.Jsii$Default, ITaggableV2.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnSnapshot(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnSnapshot(software.amazon.jsii.JsiiObjectRef objRef) CfnSnapshot(software.constructs.Construct scope, String id, CfnSnapshotProps props) Create a newAWS::ElastiCache::Snapshot. -
Method Summary
Modifier and TypeMethodDescriptionstatic StringarnForSnapshot(ISnapshotRef resource) The ARN (Amazon Resource Name) of the snapshot.Indicates the status of automatic failover for the source replication group.If true, opt-in to the next auto minor version upgrade campaign.The date and time when the source cluster was created.The name of the compute and memory capacity node type for the source cluster.The cache parameter group that is associated with the source cluster.The name of the cache subnet group associated with the source cluster.Enables data tiering.The name of the cache engine used by the source cluster.The version of the cache engine version used by the source cluster.A list of the cache nodes in the source cluster.The number of cache nodes in the source cluster.The number of node groups (shards) in this snapshot.The port number used by each cache nodes in the source cluster.The name of the Availability Zone in which the source cluster is located.Specifies the weekly time range during which maintenance on the cluster is performed.A description of the source replication group.For an automatic snapshot, the number of days for which ElastiCache retains the snapshot before deleting it.Indicates whether the snapshot is from an automatic backup (automated) or was created manually (manual).The status of the snapshot.The daily time range during which ElastiCache takes daily snapshots of the source cluster.The Amazon Resource Name (ARN) for the topic used by the source cluster for publishing notifications.The Amazon Virtual Private Cloud identifier (VPC ID) of the cache subnet group for the source cluster.The identifier of an existing cluster to create a snapshot from.Tag Manager which manages the tags for this resource.The ID of the KMS key used to encrypt the snapshot.The identifier of an existing replication group to create a snapshot from.The name of a snapshot.A reference to a Snapshot resource.getTags()A list of tags to be added to this resource.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.static BooleanChecks whether the given object is a CfnSnapshot.renderProperties(Map<String, Object> props) voidsetCacheClusterId(String value) The identifier of an existing cluster to create a snapshot from.voidsetKmsKeyId(String value) The ID of the KMS key used to encrypt the snapshot.voidsetReplicationGroupId(String value) The identifier of an existing replication group to create a snapshot from.voidsetSnapshotName(String value) The name of a snapshot.voidA list of tags to be added to this resource.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, addResourceDependency, addResourceDependency, applyCrossStackReferenceStrength, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, cfnPropertyName, getAtt, getAtt, getCfnOptions, getCfnResourceType, getEnv, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, removeDependency, removeResourceDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalId, withMethods inherited from class software.constructs.Construct
getNode, isConstructMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNode, withMethods inherited from interface software.amazon.awscdk.interfaces.IEnvironmentAware
getEnvMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnSnapshot
protected CfnSnapshot(software.amazon.jsii.JsiiObjectRef objRef) -
CfnSnapshot
protected CfnSnapshot(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnSnapshot
@Stability(Stable) public CfnSnapshot(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnSnapshotProps props) Create a newAWS::ElastiCache::Snapshot.- Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.props- Resource properties. This parameter is required.
-
-
Method Details
-
arnForSnapshot
- Parameters:
resource- This parameter is required.
-
isCfnSnapshot
Checks whether the given object is a CfnSnapshot.- Parameters:
x- This parameter is required.
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrArn
The ARN (Amazon Resource Name) of the snapshot. -
getAttrAutomaticFailover
Indicates the status of automatic failover for the source replication group. -
getAttrAutoMinorVersionUpgrade
If true, opt-in to the next auto minor version upgrade campaign. -
getAttrCacheClusterCreateTime
The date and time when the source cluster was created. -
getAttrCacheNodeType
The name of the compute and memory capacity node type for the source cluster. -
getAttrCacheParameterGroupName
The cache parameter group that is associated with the source cluster. -
getAttrCacheSubnetGroupName
The name of the cache subnet group associated with the source cluster. -
getAttrDataTiering
Enables data tiering.Data tiering is only supported for replication groups using the r6gd node type.
-
getAttrEngine
The name of the cache engine used by the source cluster. -
getAttrEngineVersion
The version of the cache engine version used by the source cluster. -
getAttrNodeSnapshots
A list of the cache nodes in the source cluster. -
getAttrNumCacheNodes
The number of cache nodes in the source cluster. -
getAttrNumNodeGroups
The number of node groups (shards) in this snapshot. -
getAttrPort
The port number used by each cache nodes in the source cluster. -
getAttrPreferredAvailabilityZone
The name of the Availability Zone in which the source cluster is located. -
getAttrPreferredMaintenanceWindow
Specifies the weekly time range during which maintenance on the cluster is performed. -
getAttrReplicationGroupDescription
A description of the source replication group. -
getAttrSnapshotRetentionLimit
For an automatic snapshot, the number of days for which ElastiCache retains the snapshot before deleting it. -
getAttrSnapshotSource
Indicates whether the snapshot is from an automatic backup (automated) or was created manually (manual). -
getAttrSnapshotStatus
The status of the snapshot.Valid values: creating | available | restoring | copying | deleting | failed | deleted.
-
getAttrSnapshotWindow
The daily time range during which ElastiCache takes daily snapshots of the source cluster. -
getAttrTopicArn
The Amazon Resource Name (ARN) for the topic used by the source cluster for publishing notifications. -
getAttrVpcId
The Amazon Virtual Private Cloud identifier (VPC ID) of the cache subnet group for the source cluster. -
getCdkTagManager
Tag Manager which manages the tags for this resource.- Specified by:
getCdkTagManagerin interfaceITaggableV2
-
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getCfnPropertyNames
- Overrides:
getCfnPropertyNamesin classCfnResource
-
getSnapshotRef
A reference to a Snapshot resource.- Specified by:
getSnapshotRefin interfaceISnapshotRef
-
getSnapshotName
The name of a snapshot. -
setSnapshotName
The name of a snapshot. -
getCacheClusterId
The identifier of an existing cluster to create a snapshot from. -
setCacheClusterId
The identifier of an existing cluster to create a snapshot from. -
getKmsKeyId
The ID of the KMS key used to encrypt the snapshot. -
setKmsKeyId
The ID of the KMS key used to encrypt the snapshot. -
getReplicationGroupId
The identifier of an existing replication group to create a snapshot from. -
setReplicationGroupId
The identifier of an existing replication group to create a snapshot from. -
getTags
A list of tags to be added to this resource. -
setTags
A list of tags to be added to this resource.
-