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

Address TODO items in preparation for 3.0 beta (3/many) #15340

Merged
merged 14 commits into from
Feb 17, 2022
Merged

Conversation

koikonom
Copy link
Contributor

@koikonom koikonom commented Feb 9, 2022

Address TODO items in preparation for 3.0 beta (3/many)

Copy link
Collaborator

@katbyte katbyte left a comment

Choose a reason for hiding this comment

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

just one comment about the renames, we should probably add the news ones and deprecate the old ones (and then put their removable behind the flag) so there sno surprise when they disappear in 3.0

Comment on lines 602 to 511
// TODO 3.0 - change this to ultra_ssd_disk_iops_read_write
"disk_iops_read_write": {
Type: pluginsdk.TypeInt,
Optional: true,
Computed: true,
},

// TODO 3.0 - change this to ultra_ssd_disk_iops_read_write
"disk_mbps_read_write": {
Type: pluginsdk.TypeInt,
Optional: true,
Computed: true,
},
Copy link
Collaborator

Choose a reason for hiding this comment

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

We should probably add the new properties and deprecate the old ones so people have some warning and can move over?

stephybun added a commit that referenced this pull request Feb 10, 2022
@koikonom koikonom changed the title Adress TODO items in preparation for 3.0 beta (3/many) Address TODO items in preparation for 3.0 beta (3/many) Feb 11, 2022
Comment on lines 541 to 533
o := out.Elem.(*pluginsdk.Resource).Schema
if features.ThreePointOhBeta() {
o["ultra_ssd_disk_iops_read_write"] = &pluginsdk.Schema{
Type: pluginsdk.TypeInt,
Optional: true,
Computed: true,
ConflictsWith: []string{"disk_iops_read_write"},
}

o["ultra_ssd_mbps_read_write"] = &pluginsdk.Schema{
Type: pluginsdk.TypeInt,
Optional: true,
Computed: true,
ConflictsWith: []string{"disk_mbps_read_write"},
}
}

return out
Copy link
Collaborator

Choose a reason for hiding this comment

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

is there a reason we are adding these in 3,0 and not just adding the new properties deprecating the old ones and removing in 3.0/waiting fort 4.0 for the removable?

Copy link
Contributor Author

@koikonom koikonom Feb 17, 2022

Choose a reason for hiding this comment

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

Alright, based on this and #15390 (comment) I came up with the approach you can see in the commit below
(00c3174)

tl;dr
2.x: There is a deprecation notice to the existing fields
3.x: The fields are renamed.

Copy link
Collaborator

@katbyte katbyte left a comment

Choose a reason for hiding this comment

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

LGTM 🚀

@koikonom
Copy link
Contributor Author

Rebased with latest main branch and resolved conflicts

@koikonom koikonom merged commit a55ec6b into main Feb 17, 2022
@koikonom koikonom deleted the todo30_3 branch February 17, 2022 20:36
@github-actions github-actions bot added this to the v2.97.0 milestone Feb 17, 2022
@github-actions
Copy link

This functionality has been released in v2.97.0 of the Terraform 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!

@github-actions
Copy link

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 contributions.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 21, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants