Skip to content

Add canonical versioned label population keys - #663

Merged
zzylol merged 38 commits into
mainfrom
feat/population-key-codec
Sep 11, 2026
Merged

zzylol merged 38 commits into
mainfrom
feat/population-key-codec

Conversation

@zzylol

@zzylol zzylol commented Sep 11, 2026

Copy link
Copy Markdown
Contributor

Existing runtime label fingerprints concatenate unescaped name=value; fragments, so one label a="b;c=d" aliases two labels a="b", c="d". This adds a versioned, canonical codec for the existing sorted label map in the shared grouping module.

The codec serializes ordered pairs as JSON and Base64, preserving delimiters, Unicode, empty populations and embedded control characters. Decoding rejects duplicate names, noncanonical ordering/serialization and unknown versions. No new DTO is introduced. Keys remain scoped by existing summary/data definitions and do not replace schema or partition identity.

Before: no shared unambiguous population-key codec was available for the next group-aware maintenance consumer. After: consumers can explicitly adopt one versioned encoding. Existing GroupingProjection serde and table-value codecs remain compatible; DP routing and persisted legacy keys are not migrated by this PR.

Validation: collision, ordering, exact serde roundtrip and malformed/duplicate/version tests pass. Existing grouping compatibility tests are included. No runtime or performance claim; explicit routing migration remains follow-up.

# Conflicts:
#	data_plane/src/precompute_engine/maintenance_runtime.rs
@zzylol
zzylol changed the base branch from feat/derived-window-cohorts to main September 11, 2026 18:36
@zzylol
zzylol marked this pull request as ready for review September 11, 2026 18:36
@zzylol
zzylol merged commit 855c024 into main Sep 11, 2026
1 check passed
@zzylol
zzylol deleted the feat/population-key-codec branch September 21, 2026 18:41
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.

1 participant