Skip to content

Conversation

@mazyu36
Copy link
Contributor

@mazyu36 mazyu36 commented Aug 8, 2025

Issue # (if applicable)

Closes #35192

Reason for this change

This change fixes an issue in DatabaseInstance.fromLookup() where port values aren't properly converted from strings to numbers.

This causes validation errors when setting up access permissions using the connections interface, as CfnSecurityGroupIngressProps requires port values to be numbers, not strings.

Description of changes

Modified instance.ts in the fromLookup method to convert the port string to a number.

Describe any new or updated permissions being added

N/A

Description of how you validated changes

Add a unit test.

Checklist


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

@aws-cdk-automation aws-cdk-automation requested a review from a team August 8, 2025 14:40
@github-actions github-actions bot added bug This issue is a bug. p2 distinguished-contributor [Pilot] contributed 50+ PRs to the CDK labels Aug 8, 2025
Copy link
Collaborator

@aws-cdk-automation aws-cdk-automation left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(This review is outdated)

@github-actions github-actions bot added the effort/small Small work item – less than a day of effort label Aug 9, 2025
@mazyu36 mazyu36 marked this pull request as ready for review August 9, 2025 09:54
@mazyu36
Copy link
Contributor Author

mazyu36 commented Aug 9, 2025

Exemption Request: The fix can be sufficiently validated with unit tests that verify port type conversion, and creating an integration test would require complex setup of dynamically referencing security group IDs between deployment stages.

@aws-cdk-automation aws-cdk-automation added the pr-linter/exemption-requested The contributor has requested an exemption to the PR Linter feedback. label Aug 9, 2025
@leonmk-aws leonmk-aws self-assigned this Sep 15, 2025
@leonmk-aws leonmk-aws added the pr-linter/exempt-integ-test The PR linter will not require integ test changes label Sep 15, 2025
@aws-cdk-automation aws-cdk-automation added the pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. label Sep 15, 2025
@aws-cdk-automation aws-cdk-automation dismissed their stale review September 15, 2025 15:52

✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.

@leonmk-aws leonmk-aws force-pushed the fix/rds-lookup-sg-fix branch from 19337e9 to b9f34da Compare September 15, 2025 15:54
@mergify
Copy link
Contributor

mergify bot commented Sep 23, 2025

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@mergify
Copy link
Contributor

mergify bot commented Sep 23, 2025

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@mergify mergify bot merged commit 973d234 into aws:main Sep 23, 2025
19 checks passed
@github-actions
Copy link
Contributor

Comments on closed issues and PRs are hard for our team to see.
If you need help, please open a new issue that references this one.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 23, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

bug This issue is a bug. distinguished-contributor [Pilot] contributed 50+ PRs to the CDK effort/small Small work item – less than a day of effort p2 pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. pr-linter/exempt-integ-test The PR linter will not require integ test changes pr-linter/exemption-requested The contributor has requested an exemption to the PR Linter feedback.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

aws-rds: cannot use connections in rds.DatabaseInstance.fromLookup

3 participants