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

aws-cdk-lib.aws_rds.DatabaseClusterProps: Deprecation Warnings #25898

Closed
2 tasks
argarinpauljohn opened this issue Jun 8, 2023 · 8 comments
Closed
2 tasks
Labels
aws-cdk-lib Related to the aws-cdk-lib package feature-request A feature should be added or improved. p2

Comments

@argarinpauljohn
Copy link

Describe the feature

use writer and readers instead
This API will be removed in the next major release.
[WARNING] aws-cdk-lib.aws_rds.DatabaseClusterProps#instances is deprecated.

use writer and readers instead
This API will be removed in the next major release.

So we fixed this by using writer and readers instead. But CDK will destroy the old database instances then recreate them. This isn't good for us as restoring the data in the new databases will require us more time and work. Would it be possible for the CDK team to handle the migration?

Use Case

It will be cumbersome backing up the data and restoring them especially in our production databases.

Proposed Solution

Handle the migration of data in the background?

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

CDK version used

2.82.0

Environment details (OS name and version, etc.)

macOS Ventura 13.3.1

@argarinpauljohn argarinpauljohn added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Jun 8, 2023
@github-actions github-actions bot added the aws-cdk-lib Related to the aws-cdk-lib package label Jun 8, 2023
@peterwoodworth
Copy link
Contributor

We do offer a migration path, have you tried this out? https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_rds-readme.html#migrating-from-instanceprops

@peterwoodworth peterwoodworth added response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. p2 and removed needs-triage This issue or PR still needs to be triaged. labels Jun 8, 2023
@github-actions
Copy link

This issue has not received a response in a while. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.

@github-actions github-actions bot added the closing-soon This issue will automatically close in 4 days unless further comments are made. label Jun 11, 2023
@argarinpauljohn
Copy link
Author

argarinpauljohn commented Jun 12, 2023

Hi @peterwoodworth! Thanks I think it works now. I did specify the is_from_legacy_instance_props property but I didn't know instance name had to be Instance1, etc.

Some questions though:

  1. In the original instance_props, there was a delete_automated_backups property. How can we specify that in writer/readers? The rds.ClusterInstance.provisioned method doesn't seem to support that.
  2. rds.DatabaseCluster.instance_identifiers used to return something when the original instance_props is used. Now it returns nothing. Our current config is 1 writer and no reader. Is this expected? We are using these identifiers to subscribe to database instance events like availability, deletion, failover, etc.

@github-actions github-actions bot removed closing-soon This issue will automatically close in 4 days unless further comments are made. response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. labels Jun 12, 2023
@peterwoodworth
Copy link
Contributor

  1. It looks to me like there is not currently a way to set deleteAutomatedBackups. With the modern reader/writer API, we would need to add this, or else you would have to use escape hatches
  2. On a quick glance it looks like instanceIdentifiers should be returning something. The instanceIdentifiers returned from this function is set as the construct property, but it looks like this is only done for readers, not for writers, so it would be expected in your case. I'm not familiar enough with this service however to know if that is right

@argarinpauljohn
Copy link
Author

Thank you @peterwoodworth! I will file separate issues to request for these features!

@peterwoodworth
Copy link
Contributor

Great @argarinpauljohn, I've triaged and responded to both of them, should be pretty easy for any contributors to implement 🙂. I think we can close this issue out now that we have two separate ones, ping me if you have any more concerns.

@github-actions
Copy link

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

@argarinpauljohn
Copy link
Author

Thanks @peterwoodworth! I will try to contribute! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
aws-cdk-lib Related to the aws-cdk-lib package feature-request A feature should be added or improved. p2
Projects
None yet
Development

No branches or pull requests

2 participants