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

Bug #607 make vrf_name immutable in apstra_datacenter_routing_zone resource #611

Conversation

chrismarget-j
Copy link
Collaborator

@chrismarget-j chrismarget-j commented Mar 10, 2024

The notes on RFE-2747 suggest that changing the VRF name in a Routing Zone is not supported, but the apstra_datacenter_routing_zone resource permitted it to be changed.

This PR adds a new Computed attribute vrf_name to the apstra_datacenter_routing_zone resource. The initial value for vrf_name is copied from name, but changes to name no longer change the vrf_name attribute in Apstra, nor do they update the vrf_name attribute in Terraform.

vrf_name is effectively immutable.

Altogether 3 resources are modified, each with the addition of the vrf_name attribute:

  • apstra_datacenter_routing_zone resource
  • apstra_datacenter_routing_zone data source
  • apstra_datacenter_routing_zones data source

In addition, major re-work to the tests for the apstra_datacenter_routing_zone and a bunch of new test helper code we can use in other resources.

Closes #607

Copy link
Collaborator Author

@chrismarget-j chrismarget-j left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

!

@bwJuniper bwJuniper self-requested a review March 12, 2024 16:52
Copy link
Collaborator

@bwJuniper bwJuniper left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks great!

@chrismarget-j chrismarget-j merged commit 0b68df3 into main Mar 12, 2024
1 check passed
@chrismarget-j chrismarget-j deleted the 607-resource-apstra_datacenter_routing_zone-may-be-doing-something-incorrectunsafe branch March 12, 2024 16:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Resource apstra_datacenter_routing_zone may be doing something incorrect/unsafe
2 participants