-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
azurerm_data_protection_backup_vault - support for immutability property #27859
base: main
Are you sure you want to change the base?
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.
Hey @katbyte, this looks good but I think we want to update some of the functionality to line up better with what the portal is doing!
internal/services/dataprotection/data_protection_backup_vault_resource.go
Outdated
Show resolved
Hide resolved
internal/services/dataprotection/data_protection_backup_vault_resource.go
Show resolved
Hide resolved
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.
The CustomizeDiff is perfect but the way it's currently written is a breaking change if people move between versions. I've left comments for how to get it working without it being a breaking change
internal/services/dataprotection/data_protection_backup_vault_resource.go
Outdated
Show resolved
Hide resolved
internal/services/dataprotection/data_protection_backup_vault_resource.go
Outdated
Show resolved
Hide resolved
@@ -55,7 +55,9 @@ The following arguments are supported: | |||
|
|||
-> **Note:** The `retention_duration_in_days` is the number of days for which deleted data is retained before being permanently deleted. Retention period till 14 days are free of cost, however, retention beyond 14 days may incur additional charges. The `retention_duration_in_days` is required when the `soft_delete` is set to `On`. | |||
|
|||
* `soft_delete` - (Optional) The state of soft delete for this Backup Vault. Possible values are `AlwaysOn`, `Off` and `On`. Defaults to `On`. | |||
* `immutability` - (Optional) The state of immutability for this Backup Vault. Possible values are `Disabled`, `Locked`, and `Unlocked`. Defaults to `Disabled`. Changing this from `Locked` to anything else forces a new Backup Vault to be created. |
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.
This is more for if we want the naming to be better but I think Unlocked
isn't very clear that it's actually enabling immutability. It'd be a bit more work on our end but what are your thoughts on changing Unlocked
to Enabled
?
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 think its best if we just keep it matching the API values even if the portal uses something else here despite it being confusing
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 once linting is good!
Change Log
Below please provide what should go into the changelog (if anything) conforming to the Changelog Format documented here.
azurerm_data_protection_backup_vault
- support for immutability property [GH-00000]This is a (please select all that apply):
Related Issue(s)
Fixes #22238
Note
If this PR changes meaningfully during the course of review please update the title and description as required.