-
Notifications
You must be signed in to change notification settings - Fork 454
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: add vsan fault domain support #1969
Conversation
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.
I have some general questions, but this PR seems overall pretty simple and shouldn't take much to get merged.
I'll be reviewing this one today. |
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.
@zxinyu08 - a couple questions:
- Should this be singular
fault_domain
versus the plural?
vsan_fault_domain {
name = "rack-1"
host_ids = [data.vsphere_host.rack1.*.id]
}
vsan_ fault_domain {
name = "rack-2"
host_ids = [data.vsphere_host.rack2.*.id]
}
If plural, I would see this more like:
vsan_fault_domains {
fault_domain = {
name = "rack-1"
host_ids = [data.vsphere_host.rack1.*.id]
}
fault_domain = {
name = "rack-2"
host_ids = [data.vsphere_host.rack2.*.id]
}
fault_domain = {
name = "rack-3"
host_ids = [data.vsphere_host.rack3.*.id]
}
}
- This configuration is specific to vSAN. Should this be
vsan_fault_domain
? - Can you confirm that renaming of the fault domains was tested successfully.?
- Can you confirm that add, remove, reassign of hosts to fault domains was tested successfully?
- Perhaps I don't see if, but is there a dependency set that
vsan_enabled
must betrue
to allowfault_domains
to be used? - If
vsan_enabled
is set to false and the fault domains still exist, what would occur? - If the
[data.vsphere_host_foo.*.id]
and[data.vsphere_host_foo.*.id]
returns an ID for the same host I assume the API will throw and error. Or should that be caught by the provider first? - If the number of hosts in
[data.vsphere_host_foo.*.id]
and[data.vsphere_host_foo.*.id]
are not equal sized, should it at least be logged? This would not be a recommended configuration. - The more I think about it, I like the mural example above, because then you could consider expecting a minimum of 3 fault domains as best practice and then logging if less than? Just an idea.
Marking as draft whilst the prior open comments are answered. 😃 |
Hi @zxinyu08 - could you take a look at my questions from the review? Let me know if you have any questions! Reference: #1969 (review) |
Hi @tenthirtyam, we've addressed the main comment by modifying the field structure to plural way. And for other questions:
|
The functionality looks OK for me, just need to add code to skip the e2e test until we have a infra for it on the Acc environment. Several more environment variables would need be introduced. Agree @vasilsatanasov? |
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.
LGTM! 🚀
Post merge, follow-up is required regarding setting it to skip the e2e test until the CI can support it and the vars that will need to be introduced, if added to e2e.
@zxinyu08 - could you rebase from |
Hi @tenthirtyam @vasilsatanasov, I think acc test in this PR for fault domain could be supported based on current CI setup. No extra host outside of cluster needed, and fault domain is supported in 7.0, it should be okay as expected. |
Thanks! I'll get this merged today and we can prepare for a release next week with the current payload. |
3e34dba
to
893de32
Compare
This functionality has been released in v2.6.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! |
1 similar comment
This functionality has been released in v2.6.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! |
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. 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. |
Description
Feat: add support for vSAN Fault Domain Service.
This feature is to support configuring vSAN Fault Domain. We added a new field
vsan_fault_domains
withfault_domain
, includingname
andhost_ids
incompute_cluster
resource. To remove all vSAN fault domains info, we need removevsan_fault_domains
whole block directly.Testing Details:
We did end to end test from 2 standalone hosts based on the vSphere 7.0 and 8.0.
Following is an example for .tf file:
Acceptance tests
Output from acceptance testing:
Release Note
Release note for CHANGELOG:
References
#1967