Describe the bug
When updating DatabaseCluster with defaultDatabaseName value ${envName}-db caused error "DatabaseName must begin with a letter and contain only alphanumeric characters".
We where forced change code into " defaultDatabaseName: ${envName}_db," and doing some data recovery hurdles.
I think CDK has been doing defaultDatabaseName value sanitatiotion and now this functionality is removed.
Regression Issue
Last Known Working CDK Library Version
2.234.1
Expected Behavior
Name with "-" should be allowed.
Current Behavior
Cannot use "-" symbol in database name.
Reproduction Steps
Create aurora db on version 2.234.1 with defaultDatabaseName containning "-" in name.
CDK allow database creation.
Updated newer CDK version.
Try to update stack and get errro "DatabaseName must begin with a letter and contain only alphanumeric characters.
Possible Solution
No response
Additional Information/Context
No response
AWS CDK Library version (aws-cdk-lib)
2.234.1
AWS CDK CLI version
--
Node.js Version
24
OS
Windows
Language
TypeScript
Language Version
No response
Other information
No response
Describe the bug
When updating DatabaseCluster with defaultDatabaseName value
${envName}-dbcaused error "DatabaseName must begin with a letter and contain only alphanumeric characters".We where forced change code into " defaultDatabaseName:
${envName}_db," and doing some data recovery hurdles.I think CDK has been doing defaultDatabaseName value sanitatiotion and now this functionality is removed.
Regression Issue
Last Known Working CDK Library Version
2.234.1
Expected Behavior
Name with "-" should be allowed.
Current Behavior
Cannot use "-" symbol in database name.
Reproduction Steps
Create aurora db on version 2.234.1 with defaultDatabaseName containning "-" in name.
CDK allow database creation.
Updated newer CDK version.
Try to update stack and get errro "DatabaseName must begin with a letter and contain only alphanumeric characters.
Possible Solution
No response
Additional Information/Context
No response
AWS CDK Library version (aws-cdk-lib)
2.234.1
AWS CDK CLI version
--
Node.js Version
24
OS
Windows
Language
TypeScript
Language Version
No response
Other information
No response