Skip to content

Conversation

@Junnygram
Copy link

refactor: convert IR map fields to slices to ensure deterministic DeepEqual

This PR refactors the Intermediate Representation (IR) to replacing map fields with slices of structs. This ensures consistent ordering of elements, which is critical for deterministic DeepEqual comparisons and preventing unnecessary xDS updates.

Key changes:

  • Replaced map[string]string with []MapEntry in IR structs.
  • Replaced map[string]CustomTag with []CustomTagMapEntry.
  • Decoupled TrafficFeatures.Telemetry from API types to enforce slice usage.
  • Updated gatewayapi translator to convert API maps to sorted IR slices.
  • Updated xds/translator to consume slice-based IR.
  • Updated test data inputs and regenerated output snapshots.

Fixes #7852.

@Junnygram Junnygram requested a review from a team as a code owner January 14, 2026 10:44
@netlify
Copy link

netlify bot commented Jan 14, 2026

Deploy Preview for cerulean-figolla-1f9435 canceled.

Name Link
🔨 Latest commit 0f04f7a
🔍 Latest deploy log https://app.netlify.com/projects/cerulean-figolla-1f9435/deploys/696ae9f55de3f80008c10ef8

@Junnygram Junnygram force-pushed the refactor/ir-map-to-slice branch from a34560c to e1ab70a Compare January 14, 2026 10:45
@Junnygram Junnygram force-pushed the refactor/ir-map-to-slice branch from e1ab70a to e53faad Compare January 14, 2026 10:49
@Junnygram Junnygram force-pushed the refactor/ir-map-to-slice branch from 536eef8 to 0f04f7a Compare January 17, 2026 01:46
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.

2 participants