-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(aws-redshift): Tables are always created with a suffix #17064
Comments
To work around this I can use an escape hatch to remove the
which results in the following Custom Resource event payload
Now |
Is it that properties passed in via a custom resource are always converted to strings? |
Thanks for the detailed bug report! Agree that the line you linked is the issue in question. Given how this is evaluated, changing the line to check if the |
- Check if the generateSuffix is explicitly "true"; - Closes aws#17064
- Check if the generateSuffix is explicitly 'true'; - Closes #17064 ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
|
- Check if the generateSuffix is explicitly 'true'; - Closes aws#17064 ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
What is the problem?
When creating a Redshift table using the Table construct the table are always created with a suffix. Looking at the code it appears that this should be an optional behavior.
Reproduction Steps
Create a table
and build CDK to generate CFN
Notice that
generateSuffix
is set to false which would mean that my table should simply have the names.my_table
What did you expect to happen?
A Redshift table created with the name
s.my_table
What actually happened?
A Redshift table created with the name
s.my_tabled8a03679
CDK CLI Version
1.126.0
Framework Version
No response
Node.js Version
NodeJS-12.0
OS
Amazon Linux 2012
Language
Typescript
Language Version
No response
Other information
I can see that the
generateSuffix: "false"
is present in the Lambda Event for the Table creation custom resourcehowever it is a string as opposed to a boolean. As a result
props.tableName.generateSuffix ?
${event.RequestId.substring(0, 8)}: ''
is evaluated to true instead of false which creates the suffix.The text was updated successfully, but these errors were encountered: