fix: Issue #2305 - Fix diff recognition for removal of network security group IDs in oci_apigateway_gateway#2307
Conversation
Signed-off-by: Justin Jones <justin.jo.jones@oracle.com>
|
Thank you for your pull request and welcome to our community! To contribute, please sign the Oracle Contributor Agreement (OCA).
To sign the OCA, please create an Oracle account and sign the OCA in Oracle's Contributor Agreement Application. When signing the OCA, please provide your GitHub username. After signing the OCA and getting an OCA approval from Oracle, this PR will be automatically updated. If you are an Oracle employee, please make sure that you are a member of the main Oracle GitHub organization, and your membership in this organization is public. |
|
Thank you for your valuable contribution. We greatly appreciate your efforts in submitting this pull request. However, I regret to inform you that we are unable to merge it directly on GitHub at this time. Our internal policy requires that all pull requests undergo thorough local testing and review before they can be merged into the main codebase. This process ensures the quality and stability of Terraform-Provider-OCI. We understand that this may cause some inconvenience, but please rest assured that your contribution is highly valued. Our team will carefully review and test your changes locally to ensure they meet our standards. We appreciate your understanding and patience in this matter. If you have any questions or need further assistance, please don't hesitate to reach out. Thank you once again for your contribution. |
|
Thank you for signing the OCA. |
Summary:
This PR addresses an issue where updating an API Gateway to remove all associated network security group IDs does not trigger a change in Terraform. The resource update logic fails to send an empty list for
network_security_group_idswhen they are removed, resulting in the NSG remaining attached.Changes:
s.D.HasChange("network_security_group_ids")and explicitly assigns the (possibly empty) list torequest.NetworkSecurityGroupIds.Testing:
network_security_group_ids.terraform planandterraform applyto verify that the NSG is properly removed from the API Gateway.This fix ensures that the Terraform provider correctly detects the removal of NSG IDs and aligns the actual state of the API Gateway with the desired configuration.