Skip to content

Add immutable attribute to TlsInspectionPolicy parameters - #18624

Open
JamesDuncanNz wants to merge 1 commit into
GoogleCloudPlatform:mainfrom
JamesDuncanNz:patch-3
Open

Add immutable attribute to TlsInspectionPolicy parameters#18624
JamesDuncanNz wants to merge 1 commit into
GoogleCloudPlatform:mainfrom
JamesDuncanNz:patch-3

Conversation

@JamesDuncanNz

Copy link
Copy Markdown
Contributor

Description

Mark name and location parameters as immutable: true on TlsInspectionPolicy.

Previously, immutable: true was missing on the URL parameters name and location in mmv1/products/networksecurity/TlsInspectionPolicy.yaml. As a result, the generated Terraform schema did not have ForceNew: true, causing Terraform to erroneously plan an in-place update when either field was changed. During apply, this resulted in an invalid PATCH request to the new resource name/location endpoint and failed on subsequent state read with:

Error: Provider produced inconsistent result after apply
Root object was present, but now absent.

Adding immutable: true ensures Terraform correctly plans a destroy-and-recreate (ForceNew) when name or location is changed.

Release Note Template for Downstream PRs (will be copied)

networksecurity: fixed `google_network_security_tls_inspection_policy` to force replacement (`ForceNew`) when `name` or `location` is modified

Added 'immutable' attribute to parameters in TlsInspectionPolicy.
@github-actions
github-actions Bot requested a review from ScottSuarez August 13, 2026 00:19
@github-actions

Copy link
Copy Markdown

Googlers: For automatic test runs see go/terraform-auto-test-runs.

@ScottSuarez, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look.

You can help make sure that review is quick by doing a self-review and by running impacted tests locally.

@modular-magician

modular-magician commented Aug 13, 2026

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes for commit 731d5f9:

Diff report

Your PR generated the following diffs in downstream repositories:

Repository Diff Link Changes
google provider View Diff 1 file changed, 2 insertions(+)
google-beta provider View Diff 1 file changed, 2 insertions(+)
terraform-google-conversion View Diff 1 file changed, 2 insertions(+)

Test report

Analytics

Total Tests Passed Skipped Affected
83 76 7 0
Affected Service Packages
  • networksecurity

Learn how VCR tests work


Step 1: Replaying Mode

🟢 All tests passed in Replaying mode! No Recording was needed.

View the replaying VCR build log

@JamesDuncanNz, @ScottSuarez VCR tests complete for 731d5f9!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants