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

azurerm_automation_software_update_configuration: set exists slice as nil when load SDK data to schema model #21995

Closed
wants to merge 1 commit into from

Conversation

wuxu92
Copy link
Contributor

@wuxu92 wuxu92 commented Jun 1, 2023

resolves: #21970

The API doesn't return the schedule block when the first version of software_update_configuration released, so I used a Decode to load the exists model in state, then cover with SDK data.

var output SoftwareUpdateConfigurationModel
if err := meta.Decode(&output); err != nil {
return err
}

It seems in some regions, like UK South, the API now returns the schedule info the GET request. we have to set the s.MonthlyOccurrence as nil before append the returned values into the schema model.

local test pass with no diff in second terraform plan

image

@wuxu92 wuxu92 marked this pull request as ready for review June 2, 2023 08:08
@jackofallops jackofallops self-assigned this Jun 19, 2023
@jackofallops
Copy link
Member

Thanks for this @wuxu92 - I've recently refactored this resource in #22204 and that PR will supersede his one, so I'm going to close this one out.

Thanks again.

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 May 25, 2024
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.

azurerm_automation_software_update_configuration | monthly_occurance issue
2 participants