feat(dwctl): resolve demand model names to serving leaves in /monitoring/demand - #1496
Draft
rushilbhat wants to merge 1 commit into
Draft
feat(dwctl): resolve demand model names to serving leaves in /monitoring/demand#1496rushilbhat wants to merge 1 commit into
rushilbhat wants to merge 1 commit into
Conversation
…ing/demand The /admin/api/v1/monitoring/demand endpoint keyed queue demand by the requested model name, so demand arriving under a customer alias or a composite (virtual) model never matched a serving-pool name in scouter and exerted no scale pressure. Resolve every reported name to its serving leaf before returning: composites follow their primary enabled component (lowest sort_order, recursively, bounded depth) to a non-composite entry whose model_name is the serving name; plain entries fold to their own model_name; names outside the catalog pass through unchanged. Counts from aliases folding to the same leaf are merged. COR-611 part B.
Deploying control-layer with
|
| Latest commit: |
aa02426
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://23a2141c.control-layer.pages.dev |
| Branch Preview URL: | https://feat-demand-alias-resolution.control-layer.pages.dev |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
COR-611 part B.
/admin/api/v1/monitoring/demandnow folds queue demand onto serving names before returning: each requested model name is resolved through the catalog — composite → primary enabled component (lowestsort_order, ties by weight/created_at), recursively (bounded, though nesting is catalog-forbidden today) — down to a non-composite entry, and reported under that entry'smodel_name. Counts merge when multiple aliases share a leaf. Unknown names and component-less composites pass through unchanged.Why
Fusillade queues under the requested name (customer alias); scouter plans in serving names. During the 2026-08-14 incident (COR-610), 370 queued
detail-zai/glm-5.2requests exerted zero scale pressure on the healthycustom-zai/glm-5.2pool because scouter classed the alias demand "unmanaged" and dropped it. After this change the same backlog is reported ascustom-zai/glm-5.2demand — scouter's existing planner just works, no scouter changes needed on this path. This is also the prerequisite for ever moving the GLM node entries offscaling: mode: fixed, which is currently load-bearing.Deployability
Safe to land independently of the other COR-611 PRs: non-alias names fold to themselves (identity), so existing behaviour is unchanged except that alias demand — previously dropped on the floor — now reaches the pool that serves it.
Tests
Five new
#[sqlx::test]integration tests (composite→leaf fold incl. trailing windows, alias merge in flat + grouped shapes, disabled-primary skip, unknown-name pass-through, plain alias→model_name). Full suite: 2,889 passed. fmt/clippy/ZDR guard clean. The onesqlx prepare --checkmismatch (query-aabf6640…) is the known local-PG17-vs-CI drift, present on pristine main; the committed file is untouched.