fix: network map namespace filter - #65
Conversation
ReviewFindings
VerdictSolid targeted fix. Items 1 and 3 are style nits. Item 2 is the one worth confirming — does any code downstream of this query use the raw |
stevefulme1
left a comment
There was a problem hiding this comment.
please see my prior comment
|
Sorry @stevefulme1 i missed your comments... Item 1: Agreed, will add parens for clarity. Item 2: The namespace/name format is already handled downstream in networkmap_map.yml.j2 (lines 9-10 and 29-30), where multus_nad_name and multus_nad_namespace are extracted separately via split('/'). No issue here. Item 3: Acknowledged. This is a pre-existing pattern across the role — refactoring to DRY it up would be out of scope for this fix. |
909853e to
3f288e4
Compare
3f288e4 to
74cf680
Compare
|
fixed :) |
Summary
source-portgroupannotation but exist in different namespaces, the network map NAD query now filters by namespace extracted from thenetwork_attachment_definitionoverride (formatnamespace/name). If no namespace is specified, the current behavior is preserved.mtv_management_network_map_overrides, preventing silent selection of only the first match.Changes
roles/mtv_management/tasks/_mtv_network_map.yml: Added assertion to validate unique IDs in network map overrides.roles/mtv_management/tasks/_mtv_network_map_process_network.yml: Added namespace filter to JMESPath query for both VMware and oVirt NAD lookups when the override contains a namespacednetwork_attachment_definition.Test plan
namespace/namenetwork_attachment_definition