serverless_cache_snapshots
Creates, updates, deletes, gets or lists a serverless_cache_snapshots resource.
Overview
| Name | serverless_cache_snapshots |
| Type | Resource |
| Id | aws.elasticache.serverless_cache_snapshots |
Fields
The following fields are returned by SELECT queries:
- describe_serverless_cache_snapshots
| Name | Datatype | Description |
|---|---|---|
arn | string | The Amazon Resource Name (ARN) of a serverless cache snapshot. Available for Valkey, Redis OSS and Serverless Memcached only. |
bytes_used_for_cache | string | The total size of a serverless cache snapshot, in bytes. Available for Valkey, Redis OSS and Serverless Memcached only. |
create_time | string | The date and time that the source serverless cache's metadata and cache data set was obtained for the snapshot. Available for Valkey, Redis OSS and Serverless Memcached only. |
expiry_time | string | The time that the serverless cache snapshot will expire. Available for Valkey, Redis OSS and Serverless Memcached only. |
kms_key_id | string | The ID of the Amazon Web Services Key Management Service (KMS) key of a serverless cache snapshot. Available for Valkey, Redis OSS and Serverless Memcached only. |
serverless_cache_configuration | string | The configuration of the serverless cache, at the time the snapshot was taken. Available for Valkey, Redis OSS and Serverless Memcached only. |
serverless_cache_snapshot_name | string | The identifier of a serverless cache snapshot. Available for Valkey, Redis OSS and Serverless Memcached only. |
snapshot_type | string | The type of snapshot of serverless cache. Available for Valkey, Redis OSS and Serverless Memcached only. |
status | string | The current status of the serverless cache. Available for Valkey, Redis OSS and Serverless Memcached only. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_serverless_cache_snapshots | select | region | ServerlessCacheName, ServerlessCacheSnapshotName, SnapshotType, NextToken, MaxResults | Returns information about serverless cache snapshots. By default, this API lists all of the customer’s serverless cache snapshots. It can also describe a single serverless cache snapshot, or the snapshots associated with a particular serverless cache. Available for Valkey, Redis OSS and Serverless Memcached only. |
create_serverless_cache_snapshot | insert | ServerlessCacheSnapshotName, ServerlessCacheName, region | KmsKeyId, Tags | This API creates a copy of an entire ServerlessCache at a specific moment in time. Available for Valkey, Redis OSS and Serverless Memcached only. |
delete_serverless_cache_snapshot | delete | ServerlessCacheSnapshotName, region | Deletes an existing serverless cache snapshot. Available for Valkey, Redis OSS and Serverless Memcached only. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
ServerlessCacheName | string | The name of an existing serverless cache. The snapshot is created from this cache. Available for Valkey, Redis OSS and Serverless Memcached only. |
ServerlessCacheSnapshotName | string | Idenfitier of the snapshot to be deleted. Available for Valkey, Redis OSS and Serverless Memcached only. |
region | string | AWS region (default: us-east-1) |
KmsKeyId | string | The ID of the KMS key used to encrypt the snapshot. Available for Valkey, Redis OSS and Serverless Memcached only. Default: NULL |
MaxResults | integer | The maximum number of records to include in the response. If more records exist than the specified max-results value, a market is included in the response so that remaining results can be retrieved. Available for Valkey, Redis OSS and Serverless Memcached only.The default is 50. The Validation Constraints are a maximum of 50. |
NextToken | string | An optional marker returned from a prior request to support pagination of results from this operation. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by max-results. Available for Valkey, Redis OSS and Serverless Memcached only. |
ServerlessCacheName | string | The identifier of serverless cache. If this parameter is specified, only snapshots associated with that specific serverless cache are described. Available for Valkey, Redis OSS and Serverless Memcached only. |
ServerlessCacheSnapshotName | string | The identifier of the serverless cache’s snapshot. If this parameter is specified, only this snapshot is described. Available for Valkey, Redis OSS and Serverless Memcached only. |
SnapshotType | string | The type of snapshot that is being described. Available for Valkey, Redis OSS and Serverless Memcached only. |
Tags | array | A list of tags to be added to the snapshot resource. A tag is a key-value pair. Available for Valkey, Redis OSS and Serverless Memcached only. |
SELECT examples
- describe_serverless_cache_snapshots
Returns information about serverless cache snapshots. By default, this API lists all of the customer’s serverless cache snapshots. It can also describe a single serverless cache snapshot, or the snapshots associated with a particular serverless cache. Available for Valkey, Redis OSS and Serverless Memcached only.
SELECT
arn,
bytes_used_for_cache,
create_time,
expiry_time,
kms_key_id,
serverless_cache_configuration,
serverless_cache_snapshot_name,
snapshot_type,
status
FROM aws.elasticache.serverless_cache_snapshots
WHERE region = '{{ region }}' -- required
AND ServerlessCacheName = '{{ ServerlessCacheName }}'
AND ServerlessCacheSnapshotName = '{{ ServerlessCacheSnapshotName }}'
AND SnapshotType = '{{ SnapshotType }}'
AND NextToken = '{{ NextToken }}'
AND MaxResults = '{{ MaxResults }}'
;
INSERT examples
- create_serverless_cache_snapshot
- Manifest
This API creates a copy of an entire ServerlessCache at a specific moment in time. Available for Valkey, Redis OSS and Serverless Memcached only.
INSERT INTO aws.elasticache.serverless_cache_snapshots (
ServerlessCacheSnapshotName,
ServerlessCacheName,
region,
KmsKeyId,
Tags
)
SELECT
'{{ ServerlessCacheSnapshotName }}',
'{{ ServerlessCacheName }}',
'{{ region }}',
'{{ KmsKeyId }}',
'{{ Tags }}'
RETURNING
arn,
bytes_used_for_cache,
create_time,
expiry_time,
kms_key_id,
serverless_cache_configuration,
serverless_cache_snapshot_name,
snapshot_type,
status
;
# Description fields are for documentation purposes
- name: serverless_cache_snapshots
props:
- name: ServerlessCacheSnapshotName
value: "{{ ServerlessCacheSnapshotName }}"
description: Required parameter for the serverless_cache_snapshots resource.
- name: ServerlessCacheName
value: "{{ ServerlessCacheName }}"
description: Required parameter for the serverless_cache_snapshots resource.
- name: region
value: "{{ region }}"
description: Required parameter for the serverless_cache_snapshots resource.
- name: KmsKeyId
value: "{{ KmsKeyId }}"
description: The ID of the KMS key used to encrypt the snapshot. Available for Valkey, Redis OSS and Serverless Memcached only. Default: NULL
description: The ID of the KMS key used to encrypt the snapshot. Available for Valkey, Redis OSS and Serverless Memcached only. Default: NULL
- name: Tags
value: "{{ Tags }}"
description: A list of tags to be added to the snapshot resource. A tag is a key-value pair. Available for Valkey, Redis OSS and Serverless Memcached only.
description: A list of tags to be added to the snapshot resource. A tag is a key-value pair. Available for Valkey, Redis OSS and Serverless Memcached only.
DELETE examples
- delete_serverless_cache_snapshot
Deletes an existing serverless cache snapshot. Available for Valkey, Redis OSS and Serverless Memcached only.
DELETE FROM aws.elasticache.serverless_cache_snapshots
WHERE ServerlessCacheSnapshotName = '{{ ServerlessCacheSnapshotName }}' --required
AND region = '{{ region }}' --required
;