aws / aws/aws-cdk

aws_elasticache: setting logDeliveryConfigurations in clusterMode: "Disabled" fails

Open
#26,294 4 comments 2 reactions 0 assignees View on GitHub
@aws-cdk/aws-elasticache bug effort/medium p2
Dominant language
TypeScript
Stars
12.9k
Forks
4.6k
Avg merge
2d 3h
Merged PRs (30d)
83

Description

### Describe the bug

From the following configuration of Redis Cluster

```
this.cfnInstance = new CfnReplicationGroup(scope, "CacheReplicationGroup", {
replicationGroupDescription: "Repliaction group description",
atRestEncryptionEnabled: false,
authToken: undefined,
autoMinorVersionUpgrade: true,
automaticFailoverEnabled: false,
cacheNodeType: "cache.t3.micro",
cacheSubnetGroupName: cfnSubnetGroup.ref,
clusterMode: "Disabled",
engine: "redis",
engineVersion: "7.0",
multiAzEnabled: false,
numNodeGroups: 1,
securityGroupIds: [this.securityGroup.securityGroupId],
snapshotRetentionLimit: 1,
snapshotWindow: undefined
});
```

Adding the following `logDeliveryConfigurations` either with `engine-log` or `slow-log` causes a deployment failure with the message `UPDATE_ROLLBACK_COMPLETE: Cluster mode updates are not supported while attempting to update additional properties.`

```
logDeliveryConfigurations: [{
destinationDetails: {
cloudWatchLogsDetails: {
logGroup: 'redis-elasticache',
},
},
destinationType: 'cloudwatch-logs',
logFormat: 'json',
logType: 'engine-log',
}],
```

### Expected Behavior

A Redis cluster update with a log delivery configuration enabled.

### Current Behavior

Deployment fails

### Reproduction Steps

1Add `logDeliveryConfiguration` to the following redis replication group config
```
this.cfnInstance = new CfnReplicationGroup(scope, "CacheReplicationGroup", {
replicationGroupDescription: "Repliaction group description",
atRestEncryptionEnabled: false,
authToken: undefined,
autoMinorVersionUpgrade: true,
automaticFailoverEnabled: false,
cacheNodeType: "cache.t3.micro",
cacheSubnetGroupName: cfnSubnetGroup.ref,
clusterMode: "Disabled",
engine: "redis",
engineVersion: "7.0",
multiAzEnabled: false,
numNodeGroups: 1,
securityGroupIds: [this.securityGroup.securityGroupId],
snapshotRetentionLimit: 1,
snapshotWindow: undefined
});
```

### Possible Solution

_No response_

### Additional Information/Context

Thank you for your help

### CDK CLI Version

2.85.0

### Framework Version

2.85.0

### Node.js Version

16.18.0

### OS

macOS 13.4.1

### Language

Typescript

### Language Version

4.9.5

### Other information

_No response_

Contributor guide

Open the contributing guide

Research direction

No repository files or tests are named; the issue centers on the CfnReplicationGroup entry point and its logDeliveryConfigurations property. Start by reproducing the Redis cluster deployment with CDK 2.85.0, then inspect the synthesized CloudFormation and related ElastiCache implementation. Done means the configuration deploys successfully or the service limitation is clearly documented.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.