Class: Aws::ElastiCache::Client
- Inherits:
-
Seahorse::Client::Base
- Object
- Seahorse::Client::Base
- Aws::ElastiCache::Client
- Includes:
- ClientStubs
- Defined in:
- lib/aws-sdk-elasticache/client.rb
Overview
An API client for ElastiCache. To construct a client, you need to configure a ‘:region` and `:credentials`.
client = Aws::ElastiCache::Client.new(
region: region_name,
credentials: credentials,
# ...
)
For details on configuring region and credentials see the [developer guide](/sdk-for-ruby/v3/developer-guide/setup-config.html).
See #initialize for a full list of supported configuration options.
Class Attribute Summary collapse
- .identifier ⇒ Object readonly private
API Operations collapse
-
#add_tags_to_resource(params = {}) ⇒ Types::TagListMessage
A tag is a key-value pair where the key and value are case-sensitive.
-
#authorize_cache_security_group_ingress(params = {}) ⇒ Types::AuthorizeCacheSecurityGroupIngressResult
Allows network ingress to a cache security group.
-
#batch_apply_update_action(params = {}) ⇒ Types::UpdateActionResultsMessage
Apply the service update.
-
#batch_stop_update_action(params = {}) ⇒ Types::UpdateActionResultsMessage
Stop the service update.
-
#complete_migration(params = {}) ⇒ Types::CompleteMigrationResponse
Complete the migration of data.
-
#copy_serverless_cache_snapshot(params = {}) ⇒ Types::CopyServerlessCacheSnapshotResponse
Creates a copy of an existing serverless cache’s snapshot.
-
#copy_snapshot(params = {}) ⇒ Types::CopySnapshotResult
Makes a copy of an existing snapshot.
-
#create_cache_cluster(params = {}) ⇒ Types::CreateCacheClusterResult
Creates a cluster.
-
#create_cache_parameter_group(params = {}) ⇒ Types::CreateCacheParameterGroupResult
Creates a new Amazon ElastiCache cache parameter group.
-
#create_cache_security_group(params = {}) ⇒ Types::CreateCacheSecurityGroupResult
Creates a new cache security group.
-
#create_cache_subnet_group(params = {}) ⇒ Types::CreateCacheSubnetGroupResult
Creates a new cache subnet group.
-
#create_global_replication_group(params = {}) ⇒ Types::CreateGlobalReplicationGroupResult
Global Datastore for Redis offers fully managed, fast, reliable and secure cross-region replication.
-
#create_replication_group(params = {}) ⇒ Types::CreateReplicationGroupResult
Creates a Redis (cluster mode disabled) or a Redis (cluster mode enabled) replication group.
-
#create_serverless_cache(params = {}) ⇒ Types::CreateServerlessCacheResponse
Creates a serverless cache.
-
#create_serverless_cache_snapshot(params = {}) ⇒ Types::CreateServerlessCacheSnapshotResponse
This API creates a copy of an entire ServerlessCache at a specific moment in time.
-
#create_snapshot(params = {}) ⇒ Types::CreateSnapshotResult
Creates a copy of an entire cluster or replication group at a specific moment in time.
-
#create_user(params = {}) ⇒ Types::User
For Redis engine version 6.0 onwards: Creates a Redis user.
-
#create_user_group(params = {}) ⇒ Types::UserGroup
For Redis engine version 6.0 onwards: Creates a Redis user group.
-
#decrease_node_groups_in_global_replication_group(params = {}) ⇒ Types::DecreaseNodeGroupsInGlobalReplicationGroupResult
Decreases the number of node groups in a Global datastore.
-
#decrease_replica_count(params = {}) ⇒ Types::DecreaseReplicaCountResult
Dynamically decreases the number of replicas in a Redis (cluster mode disabled) replication group or the number of replica nodes in one or more node groups (shards) of a Redis (cluster mode enabled) replication group.
-
#delete_cache_cluster(params = {}) ⇒ Types::DeleteCacheClusterResult
Deletes a previously provisioned cluster.
-
#delete_cache_parameter_group(params = {}) ⇒ Struct
Deletes the specified cache parameter group.
-
#delete_cache_security_group(params = {}) ⇒ Struct
Deletes a cache security group.
-
#delete_cache_subnet_group(params = {}) ⇒ Struct
Deletes a cache subnet group.
-
#delete_global_replication_group(params = {}) ⇒ Types::DeleteGlobalReplicationGroupResult
Deleting a Global datastore is a two-step process:.
-
#delete_replication_group(params = {}) ⇒ Types::DeleteReplicationGroupResult
Deletes an existing replication group.
-
#delete_serverless_cache(params = {}) ⇒ Types::DeleteServerlessCacheResponse
Deletes a specified existing serverless cache.
-
#delete_serverless_cache_snapshot(params = {}) ⇒ Types::DeleteServerlessCacheSnapshotResponse
Deletes an existing serverless cache snapshot.
-
#delete_snapshot(params = {}) ⇒ Types::DeleteSnapshotResult
Deletes an existing snapshot.
-
#delete_user(params = {}) ⇒ Types::User
For Redis engine version 6.0 onwards: Deletes a user.
-
#delete_user_group(params = {}) ⇒ Types::UserGroup
For Redis engine version 6.0 onwards: Deletes a user group.
-
#describe_cache_clusters(params = {}) ⇒ Types::CacheClusterMessage
Returns information about all provisioned clusters if no cluster identifier is specified, or about a specific cache cluster if a cluster identifier is supplied.
-
#describe_cache_engine_versions(params = {}) ⇒ Types::CacheEngineVersionMessage
Returns a list of the available cache engines and their versions.
-
#describe_cache_parameter_groups(params = {}) ⇒ Types::CacheParameterGroupsMessage
Returns a list of cache parameter group descriptions.
-
#describe_cache_parameters(params = {}) ⇒ Types::CacheParameterGroupDetails
Returns the detailed parameter list for a particular cache parameter group.
-
#describe_cache_security_groups(params = {}) ⇒ Types::CacheSecurityGroupMessage
Returns a list of cache security group descriptions.
-
#describe_cache_subnet_groups(params = {}) ⇒ Types::CacheSubnetGroupMessage
Returns a list of cache subnet group descriptions.
-
#describe_engine_default_parameters(params = {}) ⇒ Types::DescribeEngineDefaultParametersResult
Returns the default engine and system parameter information for the specified cache engine.
-
#describe_events(params = {}) ⇒ Types::EventsMessage
Returns events related to clusters, cache security groups, and cache parameter groups.
-
#describe_global_replication_groups(params = {}) ⇒ Types::DescribeGlobalReplicationGroupsResult
Returns information about a particular global replication group.
-
#describe_replication_groups(params = {}) ⇒ Types::ReplicationGroupMessage
Returns information about a particular replication group.
-
#describe_reserved_cache_nodes(params = {}) ⇒ Types::ReservedCacheNodeMessage
Returns information about reserved cache nodes for this account, or about a specified reserved cache node.
-
#describe_reserved_cache_nodes_offerings(params = {}) ⇒ Types::ReservedCacheNodesOfferingMessage
Lists available reserved cache node offerings.
-
#describe_serverless_cache_snapshots(params = {}) ⇒ Types::DescribeServerlessCacheSnapshotsResponse
Returns information about serverless cache snapshots.
-
#describe_serverless_caches(params = {}) ⇒ Types::DescribeServerlessCachesResponse
Returns information about a specific serverless cache.
-
#describe_service_updates(params = {}) ⇒ Types::ServiceUpdatesMessage
Returns details of the service updates.
-
#describe_snapshots(params = {}) ⇒ Types::DescribeSnapshotsListMessage
Returns information about cluster or replication group snapshots.
-
#describe_update_actions(params = {}) ⇒ Types::UpdateActionsMessage
Returns details of the update actions.
-
#describe_user_groups(params = {}) ⇒ Types::DescribeUserGroupsResult
Returns a list of user groups.
-
#describe_users(params = {}) ⇒ Types::DescribeUsersResult
Returns a list of users.
-
#disassociate_global_replication_group(params = {}) ⇒ Types::DisassociateGlobalReplicationGroupResult
Remove a secondary cluster from the Global datastore using the Global datastore name.
-
#export_serverless_cache_snapshot(params = {}) ⇒ Types::ExportServerlessCacheSnapshotResponse
Provides the functionality to export the serverless cache snapshot data to Amazon S3.
-
#failover_global_replication_group(params = {}) ⇒ Types::FailoverGlobalReplicationGroupResult
Used to failover the primary region to a secondary region.
-
#increase_node_groups_in_global_replication_group(params = {}) ⇒ Types::IncreaseNodeGroupsInGlobalReplicationGroupResult
Increase the number of node groups in the Global datastore.
-
#increase_replica_count(params = {}) ⇒ Types::IncreaseReplicaCountResult
Dynamically increases the number of replicas in a Redis (cluster mode disabled) replication group or the number of replica nodes in one or more node groups (shards) of a Redis (cluster mode enabled) replication group.
-
#list_allowed_node_type_modifications(params = {}) ⇒ Types::AllowedNodeTypeModificationsMessage
Lists all available node types that you can scale your Redis cluster’s or replication group’s current node type.
-
#list_tags_for_resource(params = {}) ⇒ Types::TagListMessage
Lists all tags currently on a named resource.
-
#modify_cache_cluster(params = {}) ⇒ Types::ModifyCacheClusterResult
Modifies the settings for a cluster.
-
#modify_cache_parameter_group(params = {}) ⇒ Types::CacheParameterGroupNameMessage
Modifies the parameters of a cache parameter group.
-
#modify_cache_subnet_group(params = {}) ⇒ Types::ModifyCacheSubnetGroupResult
Modifies an existing cache subnet group.
-
#modify_global_replication_group(params = {}) ⇒ Types::ModifyGlobalReplicationGroupResult
Modifies the settings for a Global datastore.
-
#modify_replication_group(params = {}) ⇒ Types::ModifyReplicationGroupResult
Modifies the settings for a replication group.
-
#modify_replication_group_shard_configuration(params = {}) ⇒ Types::ModifyReplicationGroupShardConfigurationResult
Modifies a replication group’s shards (node groups) by allowing you to add shards, remove shards, or rebalance the keyspaces among existing shards.
-
#modify_serverless_cache(params = {}) ⇒ Types::ModifyServerlessCacheResponse
This API modifies the attributes of a serverless cache.
-
#modify_user(params = {}) ⇒ Types::User
Changes user password(s) and/or access string.
-
#modify_user_group(params = {}) ⇒ Types::UserGroup
Changes the list of users that belong to the user group.
-
#purchase_reserved_cache_nodes_offering(params = {}) ⇒ Types::PurchaseReservedCacheNodesOfferingResult
Allows you to purchase a reserved cache node offering.
-
#rebalance_slots_in_global_replication_group(params = {}) ⇒ Types::RebalanceSlotsInGlobalReplicationGroupResult
Redistribute slots to ensure uniform distribution across existing shards in the cluster.
-
#reboot_cache_cluster(params = {}) ⇒ Types::RebootCacheClusterResult
Reboots some, or all, of the cache nodes within a provisioned cluster.
-
#remove_tags_from_resource(params = {}) ⇒ Types::TagListMessage
Removes the tags identified by the ‘TagKeys` list from the named resource.
-
#reset_cache_parameter_group(params = {}) ⇒ Types::CacheParameterGroupNameMessage
Modifies the parameters of a cache parameter group to the engine or system default value.
-
#revoke_cache_security_group_ingress(params = {}) ⇒ Types::RevokeCacheSecurityGroupIngressResult
Revokes ingress from a cache security group.
-
#start_migration(params = {}) ⇒ Types::StartMigrationResponse
Start the migration of data.
-
#test_failover(params = {}) ⇒ Types::TestFailoverResult
Represents the input of a ‘TestFailover` operation which test automatic failover on a specified node group (called shard in the console) in a replication group (called cluster in the console).
-
#test_migration(params = {}) ⇒ Types::TestMigrationResponse
Async API to test connection between source and target replication group.
Class Method Summary collapse
- .errors_module ⇒ Object private
Instance Method Summary collapse
- #build_request(operation_name, params = {}) ⇒ Object private
-
#initialize(options) ⇒ Client
constructor
A new instance of Client.
-
#wait_until(waiter_name, params = {}, options = {}) {|w.waiter| ... } ⇒ Boolean
Polls an API operation until a resource enters a desired state.
- #waiter_names ⇒ Object deprecated private Deprecated.
Constructor Details
#initialize(options) ⇒ Client
Returns a new instance of Client.
385 386 387 |
# File 'lib/aws-sdk-elasticache/client.rb', line 385 def initialize(*args) super end |
Class Attribute Details
.identifier ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
11442 11443 11444 |
# File 'lib/aws-sdk-elasticache/client.rb', line 11442 def identifier @identifier end |
Class Method Details
.errors_module ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
11445 11446 11447 |
# File 'lib/aws-sdk-elasticache/client.rb', line 11445 def errors_module Errors end |
Instance Method Details
#add_tags_to_resource(params = {}) ⇒ Types::TagListMessage
A tag is a key-value pair where the key and value are case-sensitive. You can use tags to categorize and track all your ElastiCache resources, with the exception of global replication group. When you add or remove tags on replication groups, those actions will be replicated to all nodes in the replication group. For more information, see [Resource-level permissions].
For example, you can use cost-allocation tags to your ElastiCache resources, Amazon generates a cost allocation report as a comma-separated value (CSV) file with your usage and costs aggregated by your tags. You can apply tags that represent business categories (such as cost centers, application names, or owners) to organize your costs across multiple services.
For more information, see [Using Cost Allocation Tags in Amazon ElastiCache] in the *ElastiCache User Guide*.
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/IAM.ResourceLevelPermissions.html [2]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/Tagging.html
491 492 493 494 |
# File 'lib/aws-sdk-elasticache/client.rb', line 491 def (params = {}, = {}) req = build_request(:add_tags_to_resource, params) req.send_request() end |
#authorize_cache_security_group_ingress(params = {}) ⇒ Types::AuthorizeCacheSecurityGroupIngressResult
Allows network ingress to a cache security group. Applications using ElastiCache must be running on Amazon EC2, and Amazon EC2 security groups are used as the authorization mechanism.
<note markdown=“1”> You cannot authorize ingress from an Amazon EC2 security group in one region to an ElastiCache cluster in another region.
</note>
556 557 558 559 |
# File 'lib/aws-sdk-elasticache/client.rb', line 556 def (params = {}, = {}) req = build_request(:authorize_cache_security_group_ingress, params) req.send_request() end |
#batch_apply_update_action(params = {}) ⇒ Types::UpdateActionResultsMessage
Apply the service update. For more information on service updates and applying them, see [Applying Service Updates].
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/applying-updates.html
608 609 610 611 |
# File 'lib/aws-sdk-elasticache/client.rb', line 608 def batch_apply_update_action(params = {}, = {}) req = build_request(:batch_apply_update_action, params) req.send_request() end |
#batch_stop_update_action(params = {}) ⇒ Types::UpdateActionResultsMessage
Stop the service update. For more information on service updates and stopping them, see [Stopping Service Updates].
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/stopping-self-service-updates.html
660 661 662 663 |
# File 'lib/aws-sdk-elasticache/client.rb', line 660 def batch_stop_update_action(params = {}, = {}) req = build_request(:batch_stop_update_action, params) req.send_request() end |
#build_request(operation_name, params = {}) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
11301 11302 11303 11304 11305 11306 11307 11308 11309 11310 11311 11312 |
# File 'lib/aws-sdk-elasticache/client.rb', line 11301 def build_request(operation_name, params = {}) handlers = @handlers.for(operation_name) context = Seahorse::Client::RequestContext.new( operation_name: operation_name, operation: config.api.operation(operation_name), client: self, params: params, config: config) context[:gem_name] = 'aws-sdk-elasticache' context[:gem_version] = '1.98.0' Seahorse::Client::Request.new(handlers, context) end |
#complete_migration(params = {}) ⇒ Types::CompleteMigrationResponse
Complete the migration of data.
768 769 770 771 |
# File 'lib/aws-sdk-elasticache/client.rb', line 768 def complete_migration(params = {}, = {}) req = build_request(:complete_migration, params) req.send_request() end |
#copy_serverless_cache_snapshot(params = {}) ⇒ Types::CopyServerlessCacheSnapshotResponse
Creates a copy of an existing serverless cache’s snapshot. Available for Redis only.
828 829 830 831 |
# File 'lib/aws-sdk-elasticache/client.rb', line 828 def copy_serverless_cache_snapshot(params = {}, = {}) req = build_request(:copy_serverless_cache_snapshot, params) req.send_request() end |
#copy_snapshot(params = {}) ⇒ Types::CopySnapshotResult
Makes a copy of an existing snapshot.
<note markdown=“1”> This operation is valid for Redis only.
</note>
Users or groups that have permissions to use the ‘CopySnapshot` operation can create their own Amazon S3 buckets and copy snapshots to it. To control access to your snapshots, use an IAM policy to control who has the ability to use the `CopySnapshot` operation. For more information about using IAM to control the use of ElastiCache operations, see [Exporting Snapshots] and [Authentication & Access Control].
You could receive the following error messages.
**Error Messages**
-
**Error Message:** The S3 bucket %s is outside of the region.
Solution: Create an Amazon S3 bucket in the same region as your snapshot. For more information, see [Step 1: Create an Amazon S3 Bucket] in the ElastiCache User Guide.
-
**Error Message:** The S3 bucket %s does not exist.
Solution: Create an Amazon S3 bucket in the same region as your snapshot. For more information, see [Step 1: Create an Amazon S3 Bucket] in the ElastiCache User Guide.
-
**Error Message:** The S3 bucket %s is not owned by the authenticated user.
Solution: Create an Amazon S3 bucket in the same region as your snapshot. For more information, see [Step 1: Create an Amazon S3 Bucket] in the ElastiCache User Guide.
-
**Error Message:** The authenticated user does not have sufficient permissions to perform the desired activity.
Solution: Contact your system administrator to get the needed permissions.
-
**Error Message:** The S3 bucket %s already contains an object with key %s.
Solution: Give the ‘TargetSnapshotName` a new and unique value. If exporting a snapshot, you could alternatively create a new Amazon S3 bucket and use this same value for `TargetSnapshotName`.
-
Error Message: ElastiCache has not been granted READ permissions %s on the S3 Bucket.
Solution: Add List and Read permissions on the bucket. For more information, see [Step 2: Grant ElastiCache Access to Your Amazon S3 Bucket] in the ElastiCache User Guide.
-
Error Message: ElastiCache has not been granted WRITE permissions %s on the S3 Bucket.
Solution: Add Upload/Delete permissions on the bucket. For more information, see [Step 2: Grant ElastiCache Access to Your Amazon S3 Bucket] in the ElastiCache User Guide.
-
Error Message: ElastiCache has not been granted READ_ACP permissions %s on the S3 Bucket.
Solution: Add View Permissions on the bucket. For more information, see [Step 2: Grant ElastiCache Access to Your Amazon S3 Bucket] in the ElastiCache User Guide.
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/backups-exporting.html [2]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/IAM.html [3]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/backups-exporting.html#backups-exporting-create-s3-bucket [4]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/backups-exporting.html#backups-exporting-grant-access
1056 1057 1058 1059 |
# File 'lib/aws-sdk-elasticache/client.rb', line 1056 def copy_snapshot(params = {}, = {}) req = build_request(:copy_snapshot, params) req.send_request() end |
#create_cache_cluster(params = {}) ⇒ Types::CreateCacheClusterResult
Creates a cluster. All nodes in the cluster run the same protocol-compliant cache engine software, either Memcached or Redis.
This operation is not supported for Redis (cluster mode enabled) clusters.
1673 1674 1675 1676 |
# File 'lib/aws-sdk-elasticache/client.rb', line 1673 def create_cache_cluster(params = {}, = {}) req = build_request(:create_cache_cluster, params) req.send_request() end |
#create_cache_parameter_group(params = {}) ⇒ Types::CreateCacheParameterGroupResult
Creates a new Amazon ElastiCache cache parameter group. An ElastiCache cache parameter group is a collection of parameters and their values that are applied to all of the nodes in any cluster or replication group using the CacheParameterGroup.
A newly created CacheParameterGroup is an exact duplicate of the default parameter group for the CacheParameterGroupFamily. To customize the newly created CacheParameterGroup you can change the values of specific parameters. For more information, see:
- ModifyCacheParameterGroup][1
-
in the ElastiCache API Reference.
- Parameters and Parameter Groups][2
-
in the ElastiCache User Guide.
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/APIReference/API_ModifyCacheParameterGroup.html [2]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/ParameterGroups.html
1766 1767 1768 1769 |
# File 'lib/aws-sdk-elasticache/client.rb', line 1766 def create_cache_parameter_group(params = {}, = {}) req = build_request(:create_cache_parameter_group, params) req.send_request() end |
#create_cache_security_group(params = {}) ⇒ Types::CreateCacheSecurityGroupResult
Creates a new cache security group. Use a cache security group to control access to one or more clusters.
Cache security groups are only used when you are creating a cluster outside of an Amazon Virtual Private Cloud (Amazon VPC). If you are creating a cluster inside of a VPC, use a cache subnet group instead. For more information, see [CreateCacheSubnetGroup].
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/APIReference/API_CreateCacheSubnetGroup.html
1842 1843 1844 1845 |
# File 'lib/aws-sdk-elasticache/client.rb', line 1842 def create_cache_security_group(params = {}, = {}) req = build_request(:create_cache_security_group, params) req.send_request() end |
#create_cache_subnet_group(params = {}) ⇒ Types::CreateCacheSubnetGroupResult
Creates a new cache subnet group.
Use this parameter only when you are creating a cluster in an Amazon Virtual Private Cloud (Amazon VPC).
1953 1954 1955 1956 |
# File 'lib/aws-sdk-elasticache/client.rb', line 1953 def create_cache_subnet_group(params = {}, = {}) req = build_request(:create_cache_subnet_group, params) req.send_request() end |
#create_global_replication_group(params = {}) ⇒ Types::CreateGlobalReplicationGroupResult
Global Datastore for Redis offers fully managed, fast, reliable and secure cross-region replication. Using Global Datastore for Redis, you can create cross-region read replica clusters for ElastiCache for Redis to enable low-latency reads and disaster recovery across regions. For more information, see [Replication Across Regions Using Global Datastore].
-
The GlobalReplicationGroupIdSuffix is the name of the Global datastore.
-
The PrimaryReplicationGroupId represents the name of the primary cluster that accepts writes and will replicate updates to the secondary cluster.
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/Redis-Global-Datastore.html
2039 2040 2041 2042 |
# File 'lib/aws-sdk-elasticache/client.rb', line 2039 def create_global_replication_group(params = {}, = {}) req = build_request(:create_global_replication_group, params) req.send_request() end |
#create_replication_group(params = {}) ⇒ Types::CreateReplicationGroupResult
Creates a Redis (cluster mode disabled) or a Redis (cluster mode enabled) replication group.
This API can be used to create a standalone regional replication group or a secondary replication group associated with a Global datastore.
A Redis (cluster mode disabled) replication group is a collection of nodes, where one of the nodes is a read/write primary and the others are read-only replicas. Writes to the primary are asynchronously propagated to the replicas.
A Redis cluster-mode enabled cluster is comprised of from 1 to 90 shards (API/CLI: node groups). Each shard has a primary node and up to 5 read-only replica nodes. The configuration can range from 90 shards and 0 replicas to 15 shards and 5 replicas, which is the maximum number or replicas allowed.
The node or shard limit can be increased to a maximum of 500 per cluster if the Redis engine version is 5.0.6 or higher. For example, you can choose to configure a 500 node cluster that ranges between 83 shards (one primary and 5 replicas per shard) and 500 shards (single primary and no replicas). Make sure there are enough available IP addresses to accommodate the increase. Common pitfalls include the subnets in the subnet group have too small a CIDR range or the subnets are shared and heavily used by other clusters. For more information, see [Creating a Subnet Group]. For versions below 5.0.6, the limit is 250 per cluster.
To request a limit increase, see [Amazon Service Limits] and choose the limit type **Nodes per cluster per instance type**.
When a Redis (cluster mode disabled) replication group has been successfully created, you can add one or more read replicas to it, up to a total of 5 read replicas. If you need to increase or decrease the number of node groups (console: shards), you can avail yourself of ElastiCache for Redis’ scaling. For more information, see [Scaling ElastiCache for Redis Clusters] in the *ElastiCache User Guide*.
<note markdown=“1”> This operation is valid for Redis only.
</note>
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/SubnetGroups.Creating.html [2]: docs.aws.amazon.com/general/latest/gr/aws_service_limits.html [3]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/Scaling.html
2830 2831 2832 2833 |
# File 'lib/aws-sdk-elasticache/client.rb', line 2830 def create_replication_group(params = {}, = {}) req = build_request(:create_replication_group, params) req.send_request() end |
#create_serverless_cache(params = {}) ⇒ Types::CreateServerlessCacheResponse
Creates a serverless cache.
2966 2967 2968 2969 |
# File 'lib/aws-sdk-elasticache/client.rb', line 2966 def create_serverless_cache(params = {}, = {}) req = build_request(:create_serverless_cache, params) req.send_request() end |
#create_serverless_cache_snapshot(params = {}) ⇒ Types::CreateServerlessCacheSnapshotResponse
This API creates a copy of an entire ServerlessCache at a specific moment in time. Available for Redis only.
3027 3028 3029 3030 |
# File 'lib/aws-sdk-elasticache/client.rb', line 3027 def create_serverless_cache_snapshot(params = {}, = {}) req = build_request(:create_serverless_cache_snapshot, params) req.send_request() end |
#create_snapshot(params = {}) ⇒ Types::CreateSnapshotResult
Creates a copy of an entire cluster or replication group at a specific moment in time.
<note markdown=“1”> This operation is valid for Redis only.
</note>
3252 3253 3254 3255 |
# File 'lib/aws-sdk-elasticache/client.rb', line 3252 def create_snapshot(params = {}, = {}) req = build_request(:create_snapshot, params) req.send_request() end |
#create_user(params = {}) ⇒ Types::User
For Redis engine version 6.0 onwards: Creates a Redis user. For more information, see [Using Role Based Access Control (RBAC)].
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/Clusters.RBAC.html
3342 3343 3344 3345 |
# File 'lib/aws-sdk-elasticache/client.rb', line 3342 def create_user(params = {}, = {}) req = build_request(:create_user, params) req.send_request() end |
#create_user_group(params = {}) ⇒ Types::UserGroup
For Redis engine version 6.0 onwards: Creates a Redis user group. For more information, see [Using Role Based Access Control (RBAC)]
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/Clusters.RBAC.html
3416 3417 3418 3419 |
# File 'lib/aws-sdk-elasticache/client.rb', line 3416 def create_user_group(params = {}, = {}) req = build_request(:create_user_group, params) req.send_request() end |
#decrease_node_groups_in_global_replication_group(params = {}) ⇒ Types::DecreaseNodeGroupsInGlobalReplicationGroupResult
Decreases the number of node groups in a Global datastore
3489 3490 3491 3492 |
# File 'lib/aws-sdk-elasticache/client.rb', line 3489 def decrease_node_groups_in_global_replication_group(params = {}, = {}) req = build_request(:decrease_node_groups_in_global_replication_group, params) req.send_request() end |
#decrease_replica_count(params = {}) ⇒ Types::DecreaseReplicaCountResult
Dynamically decreases the number of replicas in a Redis (cluster mode disabled) replication group or the number of replica nodes in one or more node groups (shards) of a Redis (cluster mode enabled) replication group. This operation is performed with no cluster down time.
3638 3639 3640 3641 |
# File 'lib/aws-sdk-elasticache/client.rb', line 3638 def decrease_replica_count(params = {}, = {}) req = build_request(:decrease_replica_count, params) req.send_request() end |
#delete_cache_cluster(params = {}) ⇒ Types::DeleteCacheClusterResult
Deletes a previously provisioned cluster. ‘DeleteCacheCluster` deletes all associated cache nodes, node endpoints and the cluster itself. When you receive a successful response from this operation, Amazon ElastiCache immediately begins deleting the cluster; you cannot cancel or revert this operation.
This operation is not valid for:
-
Redis (cluster mode enabled) clusters
-
Redis (cluster mode disabled) clusters
-
A cluster that is the last read replica of a replication group
-
A cluster that is the primary node of a replication group
-
A node group (shard) that has Multi-AZ mode enabled
-
A cluster from a Redis (cluster mode enabled) replication group
-
A cluster that is not in the ‘available` state
3804 3805 3806 3807 |
# File 'lib/aws-sdk-elasticache/client.rb', line 3804 def delete_cache_cluster(params = {}, = {}) req = build_request(:delete_cache_cluster, params) req.send_request() end |
#delete_cache_parameter_group(params = {}) ⇒ Struct
Deletes the specified cache parameter group. You cannot delete a cache parameter group if it is associated with any cache clusters. You cannot delete the default cache parameter groups in your account.
3842 3843 3844 3845 |
# File 'lib/aws-sdk-elasticache/client.rb', line 3842 def delete_cache_parameter_group(params = {}, = {}) req = build_request(:delete_cache_parameter_group, params) req.send_request() end |
#delete_cache_security_group(params = {}) ⇒ Struct
Deletes a cache security group.
<note markdown=“1”> You cannot delete a cache security group if it is associated with any clusters.
</note>
3882 3883 3884 3885 |
# File 'lib/aws-sdk-elasticache/client.rb', line 3882 def delete_cache_security_group(params = {}, = {}) req = build_request(:delete_cache_security_group, params) req.send_request() end |
#delete_cache_subnet_group(params = {}) ⇒ Struct
Deletes a cache subnet group.
<note markdown=“1”> You cannot delete a default cache subnet group or one that is associated with any clusters.
</note>
3921 3922 3923 3924 |
# File 'lib/aws-sdk-elasticache/client.rb', line 3921 def delete_cache_subnet_group(params = {}, = {}) req = build_request(:delete_cache_subnet_group, params) req.send_request() end |
#delete_global_replication_group(params = {}) ⇒ Types::DeleteGlobalReplicationGroupResult
Deleting a Global datastore is a two-step process:
-
First, you must DisassociateGlobalReplicationGroup to remove the secondary clusters in the Global datastore.
-
Once the Global datastore contains only the primary cluster, you can use the ‘DeleteGlobalReplicationGroup` API to delete the Global datastore while retainining the primary cluster using `RetainPrimaryReplicationGroup=true`.
Since the Global Datastore has only a primary cluster, you can delete the Global Datastore while retaining the primary by setting ‘RetainPrimaryReplicationGroup=true`. The primary cluster is never deleted when deleting a Global Datastore. It can only be deleted when it no longer is associated with any Global Datastore.
When you receive a successful response from this operation, Amazon ElastiCache immediately begins deleting the selected resources; you cannot cancel or revert this operation.
3991 3992 3993 3994 |
# File 'lib/aws-sdk-elasticache/client.rb', line 3991 def delete_global_replication_group(params = {}, = {}) req = build_request(:delete_global_replication_group, params) req.send_request() end |
#delete_replication_group(params = {}) ⇒ Types::DeleteReplicationGroupResult
Deletes an existing replication group. By default, this operation deletes the entire replication group, including the primary/primaries and all of the read replicas. If the replication group has only one primary, you can optionally delete only the read replicas, while retaining the primary by setting ‘RetainPrimaryCluster=true`.
When you receive a successful response from this operation, Amazon ElastiCache immediately begins deleting the selected resources; you cannot cancel or revert this operation.
<note markdown=“1”> This operation is valid for Redis only.
</note>
4140 4141 4142 4143 |
# File 'lib/aws-sdk-elasticache/client.rb', line 4140 def delete_replication_group(params = {}, = {}) req = build_request(:delete_replication_group, params) req.send_request() end |
#delete_serverless_cache(params = {}) ⇒ Types::DeleteServerlessCacheResponse
Deletes a specified existing serverless cache.
4198 4199 4200 4201 |
# File 'lib/aws-sdk-elasticache/client.rb', line 4198 def delete_serverless_cache(params = {}, = {}) req = build_request(:delete_serverless_cache, params) req.send_request() end |
#delete_serverless_cache_snapshot(params = {}) ⇒ Types::DeleteServerlessCacheSnapshotResponse
Deletes an existing serverless cache snapshot. Available for Redis only.
4237 4238 4239 4240 |
# File 'lib/aws-sdk-elasticache/client.rb', line 4237 def delete_serverless_cache_snapshot(params = {}, = {}) req = build_request(:delete_serverless_cache_snapshot, params) req.send_request() end |
#delete_snapshot(params = {}) ⇒ Types::DeleteSnapshotResult
Deletes an existing snapshot. When you receive a successful response from this operation, ElastiCache immediately begins deleting the snapshot; you cannot cancel or revert this operation.
<note markdown=“1”> This operation is valid for Redis only.
</note>
4354 4355 4356 4357 |
# File 'lib/aws-sdk-elasticache/client.rb', line 4354 def delete_snapshot(params = {}, = {}) req = build_request(:delete_snapshot, params) req.send_request() end |
#delete_user(params = {}) ⇒ Types::User
For Redis engine version 6.0 onwards: Deletes a user. The user will be removed from all user groups and in turn removed from all replication groups. For more information, see [Using Role Based Access Control (RBAC)].
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/Clusters.RBAC.html
4407 4408 4409 4410 |
# File 'lib/aws-sdk-elasticache/client.rb', line 4407 def delete_user(params = {}, = {}) req = build_request(:delete_user, params) req.send_request() end |
#delete_user_group(params = {}) ⇒ Types::UserGroup
For Redis engine version 6.0 onwards: Deletes a user group. The user group must first be disassociated from the replication group before it can be deleted. For more information, see [Using Role Based Access Control (RBAC)].
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/Clusters.RBAC.html
4464 4465 4466 4467 |
# File 'lib/aws-sdk-elasticache/client.rb', line 4464 def delete_user_group(params = {}, = {}) req = build_request(:delete_user_group, params) req.send_request() end |
#describe_cache_clusters(params = {}) ⇒ Types::CacheClusterMessage
Returns information about all provisioned clusters if no cluster identifier is specified, or about a specific cache cluster if a cluster identifier is supplied.
By default, abbreviated information about the clusters is returned. You can use the optional ShowCacheNodeInfo flag to retrieve detailed information about the cache nodes associated with the clusters. These details include the DNS address and port for the cache node endpoint.
If the cluster is in the creating state, only cluster-level information is displayed until all of the nodes are successfully provisioned.
If the cluster is in the deleting state, only cluster-level information is displayed.
If cache nodes are currently being added to the cluster, node endpoint information and creation time for the additional nodes are not displayed until they are completely provisioned. When the cluster state is available, the cluster is ready for use.
If cache nodes are currently being removed from the cluster, no endpoint information for the removed nodes is displayed.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
The following waiters are defined for this operation (see #wait_until for detailed usage):
* cache_cluster_available
* cache_cluster_deleted
4737 4738 4739 4740 |
# File 'lib/aws-sdk-elasticache/client.rb', line 4737 def describe_cache_clusters(params = {}, = {}) req = build_request(:describe_cache_clusters, params) req.send_request() end |
#describe_cache_engine_versions(params = {}) ⇒ Types::CacheEngineVersionMessage
Returns a list of the available cache engines and their versions.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
4991 4992 4993 4994 |
# File 'lib/aws-sdk-elasticache/client.rb', line 4991 def describe_cache_engine_versions(params = {}, = {}) req = build_request(:describe_cache_engine_versions, params) req.send_request() end |
#describe_cache_parameter_groups(params = {}) ⇒ Types::CacheParameterGroupsMessage
Returns a list of cache parameter group descriptions. If a cache parameter group name is specified, the list contains only the descriptions for that group.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
5069 5070 5071 5072 |
# File 'lib/aws-sdk-elasticache/client.rb', line 5069 def describe_cache_parameter_groups(params = {}, = {}) req = build_request(:describe_cache_parameter_groups, params) req.send_request() end |
#describe_cache_parameters(params = {}) ⇒ Types::CacheParameterGroupDetails
Returns the detailed parameter list for a particular cache parameter group.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
5549 5550 5551 5552 |
# File 'lib/aws-sdk-elasticache/client.rb', line 5549 def describe_cache_parameters(params = {}, = {}) req = build_request(:describe_cache_parameters, params) req.send_request() end |
#describe_cache_security_groups(params = {}) ⇒ Types::CacheSecurityGroupMessage
Returns a list of cache security group descriptions. If a cache security group name is specified, the list contains only the description of that group. This applicable only when you have ElastiCache in Classic setup
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
5620 5621 5622 5623 |
# File 'lib/aws-sdk-elasticache/client.rb', line 5620 def describe_cache_security_groups(params = {}, = {}) req = build_request(:describe_cache_security_groups, params) req.send_request() end |
#describe_cache_subnet_groups(params = {}) ⇒ Types::CacheSubnetGroupMessage
Returns a list of cache subnet group descriptions. If a subnet group name is specified, the list contains only the description of that group. This is applicable only when you have ElastiCache in VPC setup. All ElastiCache clusters now launch in VPC by default.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
5732 5733 5734 5735 |
# File 'lib/aws-sdk-elasticache/client.rb', line 5732 def describe_cache_subnet_groups(params = {}, = {}) req = build_request(:describe_cache_subnet_groups, params) req.send_request() end |
#describe_engine_default_parameters(params = {}) ⇒ Types::DescribeEngineDefaultParametersResult
Returns the default engine and system parameter information for the specified cache engine.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
6420 6421 6422 6423 |
# File 'lib/aws-sdk-elasticache/client.rb', line 6420 def describe_engine_default_parameters(params = {}, = {}) req = build_request(:describe_engine_default_parameters, params) req.send_request() end |
#describe_events(params = {}) ⇒ Types::EventsMessage
Returns events related to clusters, cache security groups, and cache parameter groups. You can obtain events specific to a particular cluster, cache security group, or cache parameter group by providing the name as a parameter.
By default, only the events occurring within the last hour are returned; however, you can retrieve up to 14 days’ worth of events if necessary.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
6603 6604 6605 6606 |
# File 'lib/aws-sdk-elasticache/client.rb', line 6603 def describe_events(params = {}, = {}) req = build_request(:describe_events, params) req.send_request() end |
#describe_global_replication_groups(params = {}) ⇒ Types::DescribeGlobalReplicationGroupsResult
Returns information about a particular global replication group. If no identifier is specified, returns information about all Global datastores.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
6675 6676 6677 6678 |
# File 'lib/aws-sdk-elasticache/client.rb', line 6675 def describe_global_replication_groups(params = {}, = {}) req = build_request(:describe_global_replication_groups, params) req.send_request() end |
#describe_replication_groups(params = {}) ⇒ Types::ReplicationGroupMessage
Returns information about a particular replication group. If no identifier is specified, ‘DescribeReplicationGroups` returns information about all replication groups.
<note markdown=“1”> This operation is valid for Redis only.
</note>
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
The following waiters are defined for this operation (see #wait_until for detailed usage):
* replication_group_available
* replication_group_deleted
6878 6879 6880 6881 |
# File 'lib/aws-sdk-elasticache/client.rb', line 6878 def describe_replication_groups(params = {}, = {}) req = build_request(:describe_replication_groups, params) req.send_request() end |
#describe_reserved_cache_nodes(params = {}) ⇒ Types::ReservedCacheNodeMessage
Returns information about reserved cache nodes for this account, or about a specified reserved cache node.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
7099 7100 7101 7102 |
# File 'lib/aws-sdk-elasticache/client.rb', line 7099 def describe_reserved_cache_nodes(params = {}, = {}) req = build_request(:describe_reserved_cache_nodes, params) req.send_request() end |
#describe_reserved_cache_nodes_offerings(params = {}) ⇒ Types::ReservedCacheNodesOfferingMessage
Lists available reserved cache node offerings.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
7622 7623 7624 7625 |
# File 'lib/aws-sdk-elasticache/client.rb', line 7622 def describe_reserved_cache_nodes_offerings(params = {}, = {}) req = build_request(:describe_reserved_cache_nodes_offerings, params) req.send_request() end |
#describe_serverless_cache_snapshots(params = {}) ⇒ Types::DescribeServerlessCacheSnapshotsResponse
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 Redis only.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
7697 7698 7699 7700 |
# File 'lib/aws-sdk-elasticache/client.rb', line 7697 def describe_serverless_cache_snapshots(params = {}, = {}) req = build_request(:describe_serverless_cache_snapshots, params) req.send_request() end |
#describe_serverless_caches(params = {}) ⇒ Types::DescribeServerlessCachesResponse
Returns information about a specific serverless cache. If no identifier is specified, then the API returns information on all the serverless caches belonging to this Amazon Web Services account.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
7772 7773 7774 7775 |
# File 'lib/aws-sdk-elasticache/client.rb', line 7772 def describe_serverless_caches(params = {}, = {}) req = build_request(:describe_serverless_caches, params) req.send_request() end |
#describe_service_updates(params = {}) ⇒ Types::ServiceUpdatesMessage
Returns details of the service updates
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
7831 7832 7833 7834 |
# File 'lib/aws-sdk-elasticache/client.rb', line 7831 def describe_service_updates(params = {}, = {}) req = build_request(:describe_service_updates, params) req.send_request() end |
#describe_snapshots(params = {}) ⇒ Types::DescribeSnapshotsListMessage
Returns information about cluster or replication group snapshots. By default, ‘DescribeSnapshots` lists all of your snapshots; it can optionally describe a single snapshot, or just the snapshots associated with a particular cache cluster.
<note markdown=“1”> This operation is valid for Redis only.
</note>
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
7999 8000 8001 8002 |
# File 'lib/aws-sdk-elasticache/client.rb', line 7999 def describe_snapshots(params = {}, = {}) req = build_request(:describe_snapshots, params) req.send_request() end |
#describe_update_actions(params = {}) ⇒ Types::UpdateActionsMessage
Returns details of the update actions
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
8111 8112 8113 8114 |
# File 'lib/aws-sdk-elasticache/client.rb', line 8111 def describe_update_actions(params = {}, = {}) req = build_request(:describe_update_actions, params) req.send_request() end |
#describe_user_groups(params = {}) ⇒ Types::DescribeUserGroupsResult
Returns a list of user groups.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
8172 8173 8174 8175 |
# File 'lib/aws-sdk-elasticache/client.rb', line 8172 def describe_user_groups(params = {}, = {}) req = build_request(:describe_user_groups, params) req.send_request() end |
#describe_users(params = {}) ⇒ Types::DescribeUsersResult
Returns a list of users.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
8242 8243 8244 8245 |
# File 'lib/aws-sdk-elasticache/client.rb', line 8242 def describe_users(params = {}, = {}) req = build_request(:describe_users, params) req.send_request() end |
#disassociate_global_replication_group(params = {}) ⇒ Types::DisassociateGlobalReplicationGroupResult
Remove a secondary cluster from the Global datastore using the Global datastore name. The secondary cluster will no longer receive updates from the primary cluster, but will remain as a standalone cluster in that Amazon region.
8302 8303 8304 8305 |
# File 'lib/aws-sdk-elasticache/client.rb', line 8302 def disassociate_global_replication_group(params = {}, = {}) req = build_request(:disassociate_global_replication_group, params) req.send_request() end |
#export_serverless_cache_snapshot(params = {}) ⇒ Types::ExportServerlessCacheSnapshotResponse
Provides the functionality to export the serverless cache snapshot data to Amazon S3. Available for Redis only.
8348 8349 8350 8351 |
# File 'lib/aws-sdk-elasticache/client.rb', line 8348 def export_serverless_cache_snapshot(params = {}, = {}) req = build_request(:export_serverless_cache_snapshot, params) req.send_request() end |
#failover_global_replication_group(params = {}) ⇒ Types::FailoverGlobalReplicationGroupResult
Used to failover the primary region to a secondary region. The secondary region will become primary, and all other clusters will become secondary.
8405 8406 8407 8408 |
# File 'lib/aws-sdk-elasticache/client.rb', line 8405 def failover_global_replication_group(params = {}, = {}) req = build_request(:failover_global_replication_group, params) req.send_request() end |
#increase_node_groups_in_global_replication_group(params = {}) ⇒ Types::IncreaseNodeGroupsInGlobalReplicationGroupResult
Increase the number of node groups in the Global datastore
8478 8479 8480 8481 |
# File 'lib/aws-sdk-elasticache/client.rb', line 8478 def increase_node_groups_in_global_replication_group(params = {}, = {}) req = build_request(:increase_node_groups_in_global_replication_group, params) req.send_request() end |
#increase_replica_count(params = {}) ⇒ Types::IncreaseReplicaCountResult
Dynamically increases the number of replicas in a Redis (cluster mode disabled) replication group or the number of replica nodes in one or more node groups (shards) of a Redis (cluster mode enabled) replication group. This operation is performed with no cluster down time.
8611 8612 8613 8614 |
# File 'lib/aws-sdk-elasticache/client.rb', line 8611 def increase_replica_count(params = {}, = {}) req = build_request(:increase_replica_count, params) req.send_request() end |
#list_allowed_node_type_modifications(params = {}) ⇒ Types::AllowedNodeTypeModificationsMessage
Lists all available node types that you can scale your Redis cluster’s or replication group’s current node type.
When you use the ‘ModifyCacheCluster` or `ModifyReplicationGroup` operations to scale your cluster or replication group, the value of the `CacheNodeType` parameter must be one of the node types returned by this operation.
8702 8703 8704 8705 |
# File 'lib/aws-sdk-elasticache/client.rb', line 8702 def list_allowed_node_type_modifications(params = {}, = {}) req = build_request(:list_allowed_node_type_modifications, params) req.send_request() end |
#list_tags_for_resource(params = {}) ⇒ Types::TagListMessage
Lists all tags currently on a named resource.
A tag is a key-value pair where the key and value are case-sensitive. You can use tags to categorize and track all your ElastiCache resources, with the exception of global replication group. When you add or remove tags on replication groups, those actions will be replicated to all nodes in the replication group. For more information, see [Resource-level permissions].
If the cluster is not in the available state, ‘ListTagsForResource` returns an error.
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/IAM.ResourceLevelPermissions.html
8780 8781 8782 8783 |
# File 'lib/aws-sdk-elasticache/client.rb', line 8780 def (params = {}, = {}) req = build_request(:list_tags_for_resource, params) req.send_request() end |
#modify_cache_cluster(params = {}) ⇒ Types::ModifyCacheClusterResult
Modifies the settings for a cluster. You can use this operation to change one or more cluster configuration parameters by specifying the parameters and the new values.
9269 9270 9271 9272 |
# File 'lib/aws-sdk-elasticache/client.rb', line 9269 def modify_cache_cluster(params = {}, = {}) req = build_request(:modify_cache_cluster, params) req.send_request() end |
#modify_cache_parameter_group(params = {}) ⇒ Types::CacheParameterGroupNameMessage
Modifies the parameters of a cache parameter group. You can modify up to 20 parameters in a single request by submitting a list parameter name and value pairs.
9335 9336 9337 9338 |
# File 'lib/aws-sdk-elasticache/client.rb', line 9335 def modify_cache_parameter_group(params = {}, = {}) req = build_request(:modify_cache_parameter_group, params) req.send_request() end |
#modify_cache_subnet_group(params = {}) ⇒ Types::ModifyCacheSubnetGroupResult
Modifies an existing cache subnet group.
9441 9442 9443 9444 |
# File 'lib/aws-sdk-elasticache/client.rb', line 9441 def modify_cache_subnet_group(params = {}, = {}) req = build_request(:modify_cache_subnet_group, params) req.send_request() end |
#modify_global_replication_group(params = {}) ⇒ Types::ModifyGlobalReplicationGroupResult
Modifies the settings for a Global datastore.
9520 9521 9522 9523 |
# File 'lib/aws-sdk-elasticache/client.rb', line 9520 def modify_global_replication_group(params = {}, = {}) req = build_request(:modify_global_replication_group, params) req.send_request() end |
#modify_replication_group(params = {}) ⇒ Types::ModifyReplicationGroupResult
Modifies the settings for a replication group. This is limited to Redis 7 and newer.
- Scaling for Amazon ElastiCache for Redis (cluster mode enabled)][1
-
in the ElastiCache User Guide
- ModifyReplicationGroupShardConfiguration][2
-
in the ElastiCache API
Reference
<note markdown=“1”> This operation is valid for Redis only.
</note>
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/scaling-redis-cluster-mode-enabled.html [2]: docs.aws.amazon.com/AmazonElastiCache/latest/APIReference/API_ModifyReplicationGroupShardConfiguration.html
9985 9986 9987 9988 |
# File 'lib/aws-sdk-elasticache/client.rb', line 9985 def modify_replication_group(params = {}, = {}) req = build_request(:modify_replication_group, params) req.send_request() end |
#modify_replication_group_shard_configuration(params = {}) ⇒ Types::ModifyReplicationGroupShardConfigurationResult
Modifies a replication group’s shards (node groups) by allowing you to add shards, remove shards, or rebalance the keyspaces among existing shards.
10137 10138 10139 10140 |
# File 'lib/aws-sdk-elasticache/client.rb', line 10137 def modify_replication_group_shard_configuration(params = {}, = {}) req = build_request(:modify_replication_group_shard_configuration, params) req.send_request() end |
#modify_serverless_cache(params = {}) ⇒ Types::ModifyServerlessCacheResponse
This API modifies the attributes of a serverless cache.
10242 10243 10244 10245 |
# File 'lib/aws-sdk-elasticache/client.rb', line 10242 def modify_serverless_cache(params = {}, = {}) req = build_request(:modify_serverless_cache, params) req.send_request() end |
#modify_user(params = {}) ⇒ Types::User
Changes user password(s) and/or access string.
10311 10312 10313 10314 |
# File 'lib/aws-sdk-elasticache/client.rb', line 10311 def modify_user(params = {}, = {}) req = build_request(:modify_user, params) req.send_request() end |
#modify_user_group(params = {}) ⇒ Types::UserGroup
Changes the list of users that belong to the user group.
10369 10370 10371 10372 |
# File 'lib/aws-sdk-elasticache/client.rb', line 10369 def modify_user_group(params = {}, = {}) req = build_request(:modify_user_group, params) req.send_request() end |
#purchase_reserved_cache_nodes_offering(params = {}) ⇒ Types::PurchaseReservedCacheNodesOfferingResult
Allows you to purchase a reserved cache node offering. Reserved nodes are not eligible for cancellation and are non-refundable. For more information, see [Managing Costs with Reserved Nodes] for Redis or
- Managing Costs with Reserved Nodes][2
-
for Memcached.
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/reserved-nodes.html [2]: docs.aws.amazon.com/AmazonElastiCache/latest/mem-ug/reserved-nodes.html
10459 10460 10461 10462 |
# File 'lib/aws-sdk-elasticache/client.rb', line 10459 def purchase_reserved_cache_nodes_offering(params = {}, = {}) req = build_request(:purchase_reserved_cache_nodes_offering, params) req.send_request() end |
#rebalance_slots_in_global_replication_group(params = {}) ⇒ Types::RebalanceSlotsInGlobalReplicationGroupResult
Redistribute slots to ensure uniform distribution across existing shards in the cluster.
10511 10512 10513 10514 |
# File 'lib/aws-sdk-elasticache/client.rb', line 10511 def rebalance_slots_in_global_replication_group(params = {}, = {}) req = build_request(:rebalance_slots_in_global_replication_group, params) req.send_request() end |
#reboot_cache_cluster(params = {}) ⇒ Types::RebootCacheClusterResult
Reboots some, or all, of the cache nodes within a provisioned cluster. This operation applies any modified cache parameter groups to the cluster. The reboot operation takes place as soon as possible, and results in a momentary outage to the cluster. During the reboot, the cluster status is set to REBOOTING.
The reboot causes the contents of the cache (for each cache node being rebooted) to be lost.
When the reboot is complete, a cluster event is created.
Rebooting a cluster is currently supported on Memcached and Redis (cluster mode disabled) clusters. Rebooting is not supported on Redis (cluster mode enabled) clusters.
If you make changes to parameters that require a Redis (cluster mode enabled) cluster reboot for the changes to be applied, see [Rebooting a Cluster] for an alternate process.
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/nodes.rebooting.html
10682 10683 10684 10685 |
# File 'lib/aws-sdk-elasticache/client.rb', line 10682 def reboot_cache_cluster(params = {}, = {}) req = build_request(:reboot_cache_cluster, params) req.send_request() end |
#remove_tags_from_resource(params = {}) ⇒ Types::TagListMessage
Removes the tags identified by the ‘TagKeys` list from the named resource. A tag is a key-value pair where the key and value are case-sensitive. You can use tags to categorize and track all your ElastiCache resources, with the exception of global replication group. When you add or remove tags on replication groups, those actions will be replicated to all nodes in the replication group. For more information, see [Resource-level permissions].
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/IAM.ResourceLevelPermissions.html
10777 10778 10779 10780 |
# File 'lib/aws-sdk-elasticache/client.rb', line 10777 def (params = {}, = {}) req = build_request(:remove_tags_from_resource, params) req.send_request() end |
#reset_cache_parameter_group(params = {}) ⇒ Types::CacheParameterGroupNameMessage
Modifies the parameters of a cache parameter group to the engine or system default value. You can reset specific parameters by submitting a list of parameter names. To reset the entire cache parameter group, specify the ‘ResetAllParameters` and `CacheParameterGroupName` parameters.
10844 10845 10846 10847 |
# File 'lib/aws-sdk-elasticache/client.rb', line 10844 def reset_cache_parameter_group(params = {}, = {}) req = build_request(:reset_cache_parameter_group, params) req.send_request() end |
#revoke_cache_security_group_ingress(params = {}) ⇒ Types::RevokeCacheSecurityGroupIngressResult
Revokes ingress from a cache security group. Use this operation to disallow access from an Amazon EC2 security group that had been previously authorized.
10903 10904 10905 10906 |
# File 'lib/aws-sdk-elasticache/client.rb', line 10903 def revoke_cache_security_group_ingress(params = {}, = {}) req = build_request(:revoke_cache_security_group_ingress, params) req.send_request() end |
#start_migration(params = {}) ⇒ Types::StartMigrationResponse
Start the migration of data.
11014 11015 11016 11017 |
# File 'lib/aws-sdk-elasticache/client.rb', line 11014 def start_migration(params = {}, = {}) req = build_request(:start_migration, params) req.send_request() end |
#test_failover(params = {}) ⇒ Types::TestFailoverResult
Represents the input of a ‘TestFailover` operation which test automatic failover on a specified node group (called shard in the console) in a replication group (called cluster in the console).
This API is designed for testing the behavior of your application in case of ElastiCache failover. It is not designed to be an operational tool for initiating a failover to overcome a problem you may have with the cluster. Moreover, in certain conditions such as large-scale operational events, Amazon may block this API.
**Note the following**
-
A customer can use this operation to test automatic failover on up to 5 shards (called node groups in the ElastiCache API and Amazon CLI) in any rolling 24-hour period.
-
If calling this operation on shards in different clusters (called replication groups in the API and CLI), the calls can be made concurrently.
-
If calling this operation multiple times on different shards in the same Redis (cluster mode enabled) replication group, the first node replacement must complete before a subsequent call can be made.
-
To determine whether the node replacement is complete you can check Events using the Amazon ElastiCache console, the Amazon CLI, or the ElastiCache API. Look for the following automatic failover related events, listed here in order of occurrance:
-
Replication group message: ‘Test Failover API called for node group <node-group-id>`
-
Cache cluster message: ‘Failover from primary node <primary-node-id> to replica node <node-id> completed`
-
Replication group message: ‘Failover from primary node <primary-node-id> to replica node <node-id> completed`
-
Cache cluster message: ‘Recovering cache nodes <node-id>`
-
Cache cluster message: ‘Finished recovery for cache nodes <node-id>`
For more information see:
- Viewing ElastiCache Events][1
-
in the *ElastiCache User Guide*
- DescribeEvents][2
-
in the ElastiCache API Reference
-
Also see, [Testing Multi-AZ ][3] in the *ElastiCache User Guide*.
[1]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/ECEvents.Viewing.html [2]: docs.aws.amazon.com/AmazonElastiCache/latest/APIReference/API_DescribeEvents.html [3]: docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/AutoFailover.html#auto-failover-test
11180 11181 11182 11183 |
# File 'lib/aws-sdk-elasticache/client.rb', line 11180 def test_failover(params = {}, = {}) req = build_request(:test_failover, params) req.send_request() end |
#test_migration(params = {}) ⇒ Types::TestMigrationResponse
Async API to test connection between source and target replication group.
11292 11293 11294 11295 |
# File 'lib/aws-sdk-elasticache/client.rb', line 11292 def test_migration(params = {}, = {}) req = build_request(:test_migration, params) req.send_request() end |
#wait_until(waiter_name, params = {}, options = {}) {|w.waiter| ... } ⇒ Boolean
Polls an API operation until a resource enters a desired state.
## Basic Usage
A waiter will call an API operation until:
-
It is successful
-
It enters a terminal state
-
It makes the maximum number of attempts
In between attempts, the waiter will sleep.
# polls in a loop, sleeping between attempts
client.wait_until(waiter_name, params)
## Configuration
You can configure the maximum number of polling attempts, and the delay (in seconds) between each polling attempt. You can pass configuration as the final arguments hash.
# poll for ~25 seconds
client.wait_until(waiter_name, params, {
max_attempts: 5,
delay: 5,
})
## Callbacks
You can be notified before each polling attempt and before each delay. If you throw ‘:success` or `:failure` from these callbacks, it will terminate the waiter.
started_at = Time.now
client.wait_until(waiter_name, params, {
# disable max attempts
max_attempts: nil,
# poll for 1 hour, instead of a number of attempts
before_wait: -> (attempts, response) do
throw :failure if Time.now - started_at > 3600
end
})
## Handling Errors
When a waiter is unsuccessful, it will raise an error. All of the failure errors extend from Waiters::Errors::WaiterFailed.
begin
client.wait_until(...)
rescue Aws::Waiters::Errors::WaiterFailed
# resource did not enter the desired state in time
end
## Valid Waiters
The following table lists the valid waiter names, the operations they call, and the default ‘:delay` and `:max_attempts` values.
| waiter_name | params | :delay | :max_attempts | | ————————— | ———————————— | ——– | ————- | | cache_cluster_available | #describe_cache_clusters | 15 | 40 | | cache_cluster_deleted | #describe_cache_clusters | 15 | 40 | | replication_group_available | #describe_replication_groups | 15 | 40 | | replication_group_deleted | #describe_replication_groups | 15 | 40 |
11405 11406 11407 11408 11409 |
# File 'lib/aws-sdk-elasticache/client.rb', line 11405 def wait_until(waiter_name, params = {}, = {}) w = waiter(waiter_name, ) yield(w.waiter) if block_given? # deprecated w.wait(params) end |
#waiter_names ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
11413 11414 11415 |
# File 'lib/aws-sdk-elasticache/client.rb', line 11413 def waiter_names waiters.keys end |