Skip to content
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

feat(rds): implement setting parameter group name #29965

Merged

Conversation

LaurenceWarne
Copy link
Contributor

@LaurenceWarne LaurenceWarne commented Apr 25, 2024

Reason for this change

I'd like to be able to set RDS parameter group names using CDK.

Description of changes

I've added a new field name to ParameterGroupProps used to populate dbClusterParameterGroupName and dbParameterGroupName where appropriate - AFAICS this couldn't be done at this level previously?

Description of how you validated changes

I've altered a couple of unit tests and an integration test. However I'm unable to run the integration test as the postgres version in the existing snapshot is deprecated (I believe this needs to be deployed before the new snapshot?) which blocks me from deploying.

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 April 25, 2024 17:20
@github-actions github-actions bot added beginning-contributor [Pilot] contributed between 0-2 PRs to the CDK p2 labels Apr 25, 2024
@LaurenceWarne LaurenceWarne force-pushed the feat/add-db-parameter-group-name-option branch from 0791219 to dc040be Compare April 25, 2024 17:20
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.

The pull request linter has failed. See the aws-cdk-automation comment below for failure reasons. If you believe this pull request should receive an exemption, please comment and provide a justification.

A comment requesting an exemption should contain the text Exemption Request. Additionally, if clarification is needed add Clarification Request to a comment.

@LaurenceWarne LaurenceWarne changed the title feat(rds): Implement setting parameter group name feat(rds): implement setting parameter group name Apr 25, 2024
@LaurenceWarne
Copy link
Contributor Author

Clarification Request: please let me know what README changes you think would be appropriate 🙂

@paulhcsun paulhcsun added the pr/reviewer-clarification-requested The contributor has requested clarification on feedback, a failing build, or a failing PR Linter run label Apr 26, 2024
This was referenced Apr 26, 2024
Copy link
Contributor

@paulhcsun paulhcsun left a comment

Choose a reason for hiding this comment

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

Hi @LaurenceWarne, thank you for the contribution!

Regarding your clarification request, you could update the README here by adding the new name property to the sample code. It's a fairly simple change so that should be sufficient.

With regards to the integ test, I've pulled your code down and tested it an ran into the same issue. I was able to resolve it by doing 2 things:

  1. Delete the existing snapshot folder for that integ test
  2. Change the rds.PostgresEngineVersion to a supported version: ``rds.PostgresEngineVersion/VER_16_2and rerun the test with the--update-on-failed` flag to regenerate the new snapshots.

@LaurenceWarne
Copy link
Contributor Author

LaurenceWarne commented Apr 30, 2024

With regards to the integ test, I've pulled your code down and tested it an ran into the same issue. I was able to resolve it by doing 2 things:

Delete the existing snapshot folder for that integ test
Change the rds.PostgresEngineVersion to a supported version: ``rds.PostgresEngineVersion/VER_16_2and rerun the test with the--update-on-failed` flag to regenerate the new snapshots.

Thanks for the guidance, should be done in the most recent commit!

If you like I can raise an issue for the other integration tests that use the same deprecated version.

@aws-cdk-automation aws-cdk-automation dismissed their stale review April 30, 2024 19:46

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

/**
* The name of this parameter group.
*
* @default CloudFormation-generated name
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
* @default CloudFormation-generated name
* @default - CloudFormation-generated name

Something I learned recently, if the value immediately after a @default tag is not the actual value but rather a sentence describing the value, you need to separate it with a dash - or else it would think that Cloudformation-generated is the default value.

@mergify mergify bot dismissed paulhcsun’s stale review May 2, 2024 13:16

Pull request has been modified.

paulhcsun
paulhcsun previously approved these changes May 2, 2024
Copy link
Contributor

@paulhcsun paulhcsun left a comment

Choose a reason for hiding this comment

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

This looks good, nice work @LaurenceWarne!

And no worries, I can create an issue to update the existing integ tests using the deprecated postgres versions. Thanks again!

@paulhcsun
Copy link
Contributor

@Mergifyio update

Copy link
Contributor

mergify bot commented May 2, 2024

update

❌ Mergify doesn't have permission to update

For security reasons, Mergify can't update this pull request. Try updating locally.
GitHub response: refusing to allow a GitHub App to create or update workflow .github/workflows/github-merit-badger.yml without workflows permission

Copy link
Contributor

mergify bot commented May 2, 2024

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).

@LaurenceWarne
Copy link
Contributor Author

LaurenceWarne commented May 4, 2024

And no worries, I can create an issue to update the existing integ tests using the deprecated postgres versions. Thanks again!

Cool 👍. Do you need me to merge main - looks to be an issue with mergify?

@paulhcsun
Copy link
Contributor

@Mergifyio update

Copy link
Contributor

mergify bot commented May 6, 2024

update

☑️ Nothing to do

  • #commits-behind>0 [📌 update requirement]
  • -closed [📌 update requirement]
  • -conflict [📌 update requirement]
  • queue-position=-1 [📌 update requirement]

@mergify mergify bot dismissed paulhcsun’s stale review May 6, 2024 17:37

Pull request has been modified.

@paulhcsun
Copy link
Contributor

Reran, should hopefully work this time!

Copy link
Contributor

mergify bot commented May 6, 2024

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).

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildv2Project1C6BFA3F-wQm2hXv2jqQv
  • Commit ID: c281111
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mergify mergify bot merged commit 50331a1 into aws:main May 6, 2024
9 checks passed
Copy link
Contributor

mergify bot commented May 6, 2024

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).

@LaurenceWarne LaurenceWarne deleted the feat/add-db-parameter-group-name-option branch May 7, 2024 07:51
@LaurenceWarne
Copy link
Contributor Author

LaurenceWarne commented May 7, 2024

🎉 thanks!

@aws-cdk-automation
Copy link
Collaborator

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.

@aws aws locked as resolved and limited conversation to collaborators Jul 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
beginning-contributor [Pilot] contributed between 0-2 PRs to the CDK p2 pr/reviewer-clarification-requested The contributor has requested clarification on feedback, a failing build, or a failing PR Linter run
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants