-
Notifications
You must be signed in to change notification settings - Fork 9.2k
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
New Resource: aws_rds_reserved_instance #26025
New Resource: aws_rds_reserved_instance #26025
Conversation
Currently trying to think through how to write acc tests for this type of resource as reservations cannot be deleted and are valid for the duration of the specified offering id once created. |
@brittandeyoung Thanks for your work on this! After a quick skim, it's looking very promising. We've also been thinking about how to test. Testing is important but there is precedent for things we simply cannot test. Rather than hold something up indefinitely, we may have to do best effort and rely on the community for reports of problems. Is this really it for API operations for reserved instances? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work 👍 👀
There has been some discussion with the provider team about this potentially needing to be written as a framework resource instead of using the standard SDK method. I am currently waiting on direction from the team on this, and will make required modifications when I hear back. |
Hi @brittandeyoung , any update regarding the feature? It's awesome and I think that our team is not the only one who's waiting for it |
@zhelanov Thank you for the bump on this PR. I have been working on a few other contributions as well and forgot about this one. I will be this updated to resolve the conflicts and have passing tests. Then wait for the provider team to review. |
@YakDriver Sorry for the delay in getting back to this PR. It has been updated with all recommendations and checks are all passing. |
Here's a regex that can be helpful for finding db instance classes in the tests and docs:
|
I have added a data source for The cheapest test we will be able to run is the 102$ up front instance offering.
|
@YakDriver I have added the This test will cost around $102 per run and vary based on the region testing is done in. I do not have an AWS account where I can simply rack up a $102 charge each time I attempt to validate my tests =) . Does the Hashi team have an account where these tests can be validated in? At this point my code is ready for another review. |
Something is up with the |
* Added website documentation for the `aws_rds_reserved_instance` resource.
* remove commented code for update functions as this type of resource cannot be updated.
* updated resource deletion warning wording * updated resource deletion warning to be bold
* Add update function to support updating tags * Amend `offering_id` field to ForceNew
* Amend reserved instance resource constants * Amend rds const for tags * Amend Docs to better match examples
* Amend imports to work with new changes to main
* Amend resource schema field recurring_charges to TypeSet
* Created flattening function for recurring charges schema item
* update start_time field to convert time value to string
* Added PR Change Log File
Add the datasource for reserved instance offerings.
Add tests for `aws_rds_reserved_instance` resource
Added the website documentation for the `aws_rds_reserved_instance_offering` datasource.
updated the `aws_rds_reserved_instance` docs to use the newly created datasource for reserved instance offerings
Resolve terraform parsing issue by using number as string
Update the change log to also include the new data source
* remove string conversion of variable
0d9531b
to
afd3c56
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! 🎉
This functionality has been released in v4.35.0 of the Terraform AWS Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you! |
I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. |
Community Note
Closes #8521
Output from acceptance testing: