refactor!: retire the serving-class presets, grants and default classes
Merged
HA
2d ago+950+950+012345678901234567890123456789-6585-6585-0123456789012345678901234567890123456789
Summary
Retires the interactive / throughput serving-class presets, per-account class grants and account/overlay default classes. They aren't used: no account holds a grant or a default class, no overlay sets a default class, no model declares presets, and no realtime request has named a class suffix recently. Removing them shrinks the routing path before model class routing (#1908) lands on top of it.
What changes
Onwards
serving::resolvereturns the overlay's explicit targets (custom) or nothing (standard), plus the self-hosted restriction. Daemon legs still get no targets.- Class suffixes are no longer parsed: a realtime
alias:interactiveis an ordinary (unknown) model name, so it gets a 404 instead of a 403 or a class. PoolSpec.serving_classes,AccountServing.granted/default_classandServingOverlay.default_classare gone. Stored configs that still carry them load with those fields ignored.onwards_serving_class_requests_totalkeeps its labels;requestedis now always empty.
dwctl
- The inference middleware no longer strips or interprets realtime class suffixes. Flex, background and batch uploads still discard a model suffix after a shape check, unchanged (now in
inference/model_selector.rs). - The admin API drops
granted_serving_classesanddefault_serving_classfrom users and organisations (PATCH ignores them),default_serving_classfrom overlays, andserving_classesfrom model responses. - Model catalog:
serving_classesis accepted only as an empty map, so existing files still load. The writer keeps the column{}. - Organisation catalog:
default_classis removed.class_pricingacceptsstandardandcustom; rows the catalog owned under the old class names are retired on the next apply. - Billing is unchanged: the resolved outcome is still
standard, orcustomwhen overlay targets applied.
Dashboard
- Removes the grant, default-class and preset views; the self-hosted and toleration controls stay.
No migrations. The now-unused columns stay until a later migration drops them.
Compatibility notes
- Admin API clients that send the removed fields have them ignored; responses no longer include them.
- Catalog files with a non-empty
serving_classesmap or an overlaydefault_classnow fail validation with an explicit message.
Testing
just lint rust,just lint tsjust test rust(4225 tests),just test ts(804 tests)- onwards clippy and fmt (no new warnings)
.sqlxregenerated against a freshly migrated database;cargo sqlx prepare --check --workspacepassesmodel-provisioning.schema.jsonregenerated
🤖 Generated with Claude Code