|
1 | 1 | --- |
| 2 | +# NOTE: The Create, Update and Delete functions in the generated resource file |
| 3 | +# (internal/provider/resource_catalystcenter_fabric_l3_virtual_network.go) contain |
| 4 | +# hand-written logic that mirrors several undocumented Catalyst Center constraints |
| 5 | +# around Layer 3 Virtual Networks, in particular anchored VNs and the |
| 6 | +# `merge_fabric_sites` (additive) mode. Specifically: |
| 7 | +# * Anchored Create is a two-phase POST+PUT (CatC rejects POST with multiple |
| 8 | +# fabricIds when anchoredSiteId is set). |
| 9 | +# * Anchored Update splits a combined add+remove of fabricIds into two |
| 10 | +# sequential PUTs (CatC errorCode NCHS20477). |
| 11 | +# * Anchored Delete pre-shrinks fabricIds to the anchor only before DELETE |
| 12 | +# (CatC errorCode NCHS20691). |
| 13 | +# * `anchored_site_id` is marked requires_replace because CatC does not allow |
| 14 | +# adding, changing, or removing the anchor of an existing L3 VN. |
| 15 | +# * `INFRA_VN` / `DEFAULT_VN` cannot be anchored and are managed via PUT only. |
| 16 | +# If you re-run `go generate`, remove the //template:begin/end markers around |
| 17 | +# these hand-edited functions so they are preserved. |
2 | 18 | name: Fabric L3 Virtual Network |
3 | 19 | rest_endpoint: /dna/intent/api/v1/sda/layer3VirtualNetworks |
4 | 20 | id_from_query_path: response.0 |
@@ -31,8 +47,9 @@ attributes: |
31 | 47 | test_value: "[catalystcenter_fabric_site.test.id]" |
32 | 48 | - model_name: anchoredSiteId |
33 | 49 | data_path: "0" |
| 50 | + requires_replace: true |
34 | 51 | response_data_path: response.0.anchoredSiteId |
35 | | - description: Fabric ID of the fabric site this layer 3 virtual network is to be anchored at. |
| 52 | + description: "Fabric ID of the fabric site this layer 3 virtual network is to be anchored at. Must be one of the `fabric_ids` entries. Changing this value (including setting or clearing it) forces resource replacement, because Catalyst Center does not allow adding, changing, or removing the anchor of an existing Layer 3 Virtual Network." |
36 | 53 | type: String |
37 | 54 | example: "" |
38 | 55 | exclude_test: true |
|
0 commit comments