aws-cloudformation / aws-cloudformation/cloudformation-coverage-roadmap

AWS::ElastiCache::ReplicationGroup - AWS::ElastiCache - Unable to scale up a cluster

Open
#383 6 comments 8 reactions 0 assignees View on GitHub
bug? database
Dominant language
No language data
Stars
1.1k
Forks
62
PR merge metrics
No merged PRs in 30d

Description

## 1. Title

#### AWS::ElastiCache - Unable to scale up a cluster

## 2. Scope of request

e) other coverage-related issue with the resource/attribute/option

## 3. Expected behavior

I have a Redis cluster with a single node. I tried to scale up the cluster to a multi-node cluster by CloudFormation stack. But it fails on applying the stack.

Current cluster have single node without automatic failover. The cluster is created by the following CloudFormation resource:
```yaml
MyRedisCludster:
Type: "AWS::ElastiCache::ReplicationGroup"
Properties:
ReplicationGroupDescription: "My cluster"
EngineVersion: "5.0.5"
CacheNodeType: "cache.t3.micro"
Engine: "redis"
NumCacheClusters: 1
AutomaticFailoverEnabled: "false"
```

Then I tried to scale-up the cluster: increase to two of nodes, and enable automatic failover by the following:

```yaml
MyRedisCludster:
Type: "AWS::ElastiCache::ReplicationGroup"
Properties:
ReplicationGroupDescription: "My cluster"
EngineVersion: "5.0.5"
CacheNodeType: "cache.t3.micro"
Engine: "redis"
NumCacheClusters: 2 # <-- Update
AutomaticFailoverEnabled: "true" # <-- Update
```

The stack will fail and says the following message:

```
Replication group must have at least one read replica to enable autofailover.
```

The stack should complete updating the cluster successfully.

## 4. Suggest specific test cases

1. Create a cluster with a single-node.
2. Modify the template to scale-up to two-nodes cluster and failover enabled.
3. Apply the template.
3. The stack finishes with no errors
4. The cluster has two nodes and the failover is enabled.

## 5. Helpful Links to speed up research and evaluation

## 6. Category (required) - Will help with tagging and be easier to find by other users to +1

3. DB (ElastiCache)

## 7. Any additional context (optional)

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the update with the two CloudFormation AWS::ElastiCache::ReplicationGroup templates described in the issue, then compare the resulting stack error with the requested node and failover state. Done means the stack updates successfully, the cluster has two nodes, and automatic failover is enabled.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, redis
Domain
cloud, databases, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.