-
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_mssql_database
- threat_detection_policy.0.storage_*
can now be correctly set as empty
#19670
Conversation
mbfrahry
commented
Dec 14, 2022
•
edited
Loading
edited
… detection policies
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 🦀
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.
Left a few comments inline, since I think this'll break removing these?
@@ -742,10 +742,10 @@ func expandMsSqlServerSecurityAlertPolicy(d *pluginsdk.ResourceData) sql.Databas | |||
if v, ok := securityAlert["retention_days"]; ok { | |||
properties.RetentionDays = utils.Int32(int32(v.(int))) | |||
} | |||
if v, ok := securityAlert["storage_account_access_key"]; ok { | |||
if v, ok := securityAlert["storage_account_access_key"]; ok && v.(string) != "" { |
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 doing this means these can no longer be removed, can we add a test removing these to confirm that works?
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.
It was all good with no code changes but I added a test to confirm!
properties.StorageAccountAccessKey = utils.String(v.(string)) | ||
} | ||
if v, ok := securityAlert["storage_endpoint"]; ok { | ||
if v, ok := securityAlert["storage_endpoint"]; ok && v.(string) != "" { |
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 doing this means these can no longer be removed, can we add a test removing these to confirm that works?
This functionality has been released in v3.36.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! |
…now be correctly set as empty (hashicorp#19670)
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. |