[aws-rds] ParameterGroup is missing from CloudFormation template
See original GitHub issueSince version 1.58.0 ParameterGroup resources are missing from the generated CloudFormation template.
Reproduction Steps
- Create a new cdk app using version 1.51.0 and add the following code in the stack:
new ParameterGroup(this, "RDS-ParameterGroup", {
family: "mysql:5.7",
});
- Run the
cdk synth
command and verify that theAWS::RDS::DBParameterGroup
resource exists in the generated CloudFormation template. - Now update cdk to version 1.58.0 and modify the ParameterGroup to:
new ParameterGroup(this, "RDS-ParameterGroup", {
engine: DatabaseInstanceEngine.mysql({
version: MysqlEngineVersion.VER_5_7,
}),
});
- Run the
cdk synth
command and view the generated CloudFormation template. TheAWS::RDS::DBParameterGroup
resource is missing.
What did you expect to happen?
The AWS::RDS::DBParameterGroup
resource should exist in both versions of aws cdk.
What actually happened?
The AWS::RDS::DBParameterGroup
resource exists in version 1.51.0 but not in 1.58.0.
Environment
- CLI Version: 1.58.0
- Framework Version: 1.58.0
- Node.js Version: 14.5.0
- OS: Windows 10
- Language (Version): TypeScript (3.9.6)
This is 🐛 Bug Report
Issue Analytics
- State:
- Created 3 years ago
- Comments:9 (5 by maintainers)
Top Results From Across the Web
Working with parameter groups - AWS Documentation
An example is when you want to include most of an existing DB parameter group's custom parameters and values in a new DB...
Read more >How do you associate a IAM Role with an Aurora Cluster ...
When I run aws rds describe-db-clusters I see an entry for "AssociatedRoles" that holds an array of objects with a Status and RoleArn....
Read more >Why You Should Always Use a Custom DB Parameter Group ...
For AWS RDS instances, you manage your database engine configuration through the use of parameters in a DB parameter group. DB parameter groups...
Read more >aws_db_parameter_group | Resources | hashicorp/aws
Browse aws documentation ... Provides an RDS DB parameter group resource. ... For an example of the aws_db_parameter_group in use, follow the Manage...
Read more >aws rds cli -- need to search the db-parameter-group(s) for a ...
Example aws rds describe-db-parameters --db-parameter-group-name xxxx --query 'Parameters[].{ParameterName: ParameterName, ParameterValue: ParameterValue}' ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@lossanarch if you want to shoot me a quick PR (doesn’t have to be super polished, just a draft with the rough proposal is fine), I’d be down to discuss the concrete steps to fix this 😉.
Hey @manospasj ,
yes, the issue is exactly what @Chriscbr said. Basically, the
ParameterGroup
class is used both forAWS::RDS::DBParameterGroup
andAWS::RDS::DBClusterParameterGroup
, and creates the correct underlying resource when it’s passed toInstance
orCluster
, respectively.Unfortunately, we can’t have multiple CloudFormation resource types there. But I’ll try to update the docs to make it sure it’s more clear.
Nope, that is not the behavior currently. The second call, to
bindToCluster()
, will actually create theAWS::RDS::DBClusterParameterGroup
. So you’ll have 2 groups, anAWS::RDS::DBParameterGroup
and anAWS::RDS::DBClusterParameterGroup
.