Skip to content

Conversation

@hassanazharkhan
Copy link
Contributor

Issue # (if applicable)

Closes #32280

Reason for this change

To introduce a support of Serveless Instances to be auto paused after certain interval.

Description of changes

Use to set SecondsUntilAutoPause to something other than the default of 5 minutes.

Describe any new or updated permissions being added

No new IAM permissions.

Description of how you validated changes

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 January 7, 2025 22:58
@github-actions github-actions bot added valued-contributor [Pilot] contributed between 6-12 PRs to the CDK effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. p2 labels Jan 7, 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.

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.

@hassanazharkhan hassanazharkhan changed the title feat(aws-rds): support SecondsUntilAutoPause for serverless instance feat(rds): support SecondsUntilAutoPause for serverless instance Jan 7, 2025
@codecov
Copy link

codecov bot commented Jan 7, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 82.37%. Comparing base (c4fceb2) to head (16dbc17).
Report is 219 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #32787   +/-   ##
=======================================
  Coverage   82.37%   82.37%           
=======================================
  Files         120      120           
  Lines        6933     6933           
  Branches     1169     1169           
=======================================
  Hits         5711     5711           
  Misses       1119     1119           
  Partials      103      103           
Flag Coverage Δ
suite.unit 85.26% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
packages/aws-cdk ∅ <ø> (∅)
packages/aws-cdk-lib/core 85.26% <ø> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@aws-cdk-automation aws-cdk-automation dismissed their stale review January 15, 2025 00:10

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

@aws-cdk-automation
Copy link
Collaborator

This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state.

1 similar comment
@aws-cdk-automation
Copy link
Collaborator

This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state.

Copy link
Contributor

@mazyu36 mazyu36 left a comment

Choose a reason for hiding this comment

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

Thank you for your contribution.
The current changes contain breaking changes that need to be fixed.
Please refer to the comments for details.​​​​​​​​​​​​​​​​

@aaythapa aaythapa self-assigned this Feb 13, 2025
Copy link
Contributor

@aaythapa aaythapa left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution! Small comments

/**
* The number of seconds until a serverless cluster is paused.
*/
protected readonly secondsUntilAutoPause?: number;
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: is this supposed to be Duration

* @default undefined - RDS default setting is 300 seconds (five minutes).
* @see https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/aurora-serverless-v2-auto-pause.html
*/
readonly secondsUntilAutoPause?: Duration;
Copy link
Contributor

@aaythapa aaythapa Feb 18, 2025

Choose a reason for hiding this comment

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

Looks like the ServerlessCluster has this property named as autoPause here. Since we can't change the name of that prop I'd prefer to keep the prop name consistent since they do the same thing. Maybe the same description as well?


this.serverlessV2MaxCapacity = props.serverlessV2MaxCapacity ?? 2;
this.serverlessV2MinCapacity = props.serverlessV2MinCapacity ?? 0.5;
this.secondsUntilAutoPause = props.secondsUntilAutoPause?.toSeconds();
Copy link
Contributor

@aaythapa aaythapa Feb 18, 2025

Choose a reason for hiding this comment

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

If props.secondsUntilAutoPause is undefined will this.secondsUntilAutoPause be set to undefined or 0? I ask because in the ServerlessCluster version of this prop they check if its 0 and then set it to undefined here. I suspect this might be why the integ tests in the build are failing as well

@aaythapa aaythapa removed their assignment Feb 24, 2025
@aws-cdk-automation
Copy link
Collaborator

This PR has been in the BUILD FAILING state for 3 weeks, and looks abandoned. Note that PRs with failing linting check or builds are not reviewed, please ensure your build is passing

To prevent automatic closure:

  • Resume work on the PR
  • OR request an exemption by adding a comment containing 'Exemption Request' with justification e.x "Exemption Request: "
  • OR request clarification by adding a comment containing 'Clarification Request' with a question e.x "Clarification Request: "

This PR will automatically close in 14 days if no action is taken.

@mikeparas
Copy link

@hassanazharkhan Are you able to make the suggested fixes from @aaythapa ? If not, I'd like to take a look.

@hassanazharkhan
Copy link
Contributor Author

@hassanazharkhan Are you able to make the suggested fixes from @aaythapa ? If not, I'd like to take a look.

I'll get it fixed today, Thanks

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildv2Project1C6BFA3F-wQm2hXv2jqQv
  • Commit ID: 16dbc17
  • Result: FAILED
  • Build Logs (available for 30 days)

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

@GavinZZ GavinZZ self-assigned this Mar 13, 2025
@aws-cdk-automation
Copy link
Collaborator

This PR has been in the BUILD FAILING state for 3 weeks, and looks abandoned. Note that PRs with failing linting check or builds are not reviewed, please ensure your build is passing

To prevent automatic closure:

  • Resume work on the PR
  • OR request an exemption by adding a comment containing 'Exemption Request' with justification e.x "Exemption Request: "
  • OR request clarification by adding a comment containing 'Clarification Request' with a question e.x "Clarification Request: "

This PR will automatically close in 14 days if no action is taken.

@aws-cdk-automation
Copy link
Collaborator

This PR has been deemed to be abandoned, and will be automatically closed. Please create a new PR for these changes if you think this decision has been made in error.

@aws-cdk-automation aws-cdk-automation added the closed-for-staleness This issue was automatically closed because it hadn't received any attention in a while. label Apr 16, 2025
@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 Apr 16, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

closed-for-staleness This issue was automatically closed because it hadn't received any attention in a while. effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. p2 valued-contributor [Pilot] contributed between 6-12 PRs to the CDK

Projects

None yet

Development

Successfully merging this pull request may close these issues.

rds.DatabaseCluster: Support SecondsUntilAutoPause setting in Aurora Serverless V2

6 participants