control-plane: add enabled flag to data planes#3175
Draft
GregorShear wants to merge 1 commit into
Draft
Conversation
GregorShear
force-pushed
the
greg/data-plane-enabled
branch
from
July 15, 2026 14:07
2973822 to
7da68b3
Compare
Adds an `enabled` boolean column to the `data_planes` table (default true) so operators can retire a data plane from new selection without deleting its record: a disabled plane keeps serving existing tasks but is filtered out of listings that opt in. Exposes `enabled` on the GraphQL `DataPlane` type and adds an optional `filter` argument to the `dataPlanes` query, following the `inviteLinks`/`alertConfigs` filter pattern: a `DataPlanesFilter` input object whose `enabled` field reuses the shared `filters::BoolFilter`. Because the flag lives in the database rather than the authorization snapshot, the filter resolves the matching name set and is applied before pagination so page sizes and cursors remain correct.
GregorShear
force-pushed
the
greg/data-plane-enabled
branch
from
July 15, 2026 14:12
7da68b3 to
2fb5f6d
Compare
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
Adds an
enabledboolean flag to data planes and lets thedataPlanesGraphQL query filter on it.data_planes.enabledcolumn,boolean NOT NULL DEFAULT true. Existing planes stay enabled. Includes aSELECT (enabled)grant toauthenticated(matching thedekaf_addressmigration).enabled: Boolean!on theDataPlanetype, and adds an optionalenabled: Booleanargument to thedataPlanesquery. Omitting the argument returns both enabled and disabled planes; passingtrue/falsenarrows to matching planes.Why
Gives operators a way to retire a data plane from new selection without deleting its record — a disabled plane keeps serving existing tasks but can be filtered out of listings.
Notes
enabledflag lives in the database, not the authorization snapshot, so the filter resolves the matching name set from the DB and is applied before pagination, keeping page sizes and cursors correct.publicDataPlanesquery (pre-signup plane selection) is intentionally left unchanged; filtering disabled planes out of new-signup selection would be a natural follow-up if desired.Test plan
test_graphql_data_planes_enabled_filtercovers all three cases (no argument → both planes;enabled: true→ enabled only;enabled: false→ disabled only).cargo test -p control-plane-api data_planes→ 15/15 pass.