Skip to content

feat: manage deployment slots from project status - #9887

Open
pjain1 wants to merge 4 commits into
mainfrom
ui_hibernate_slots
Open

pjain1 wants to merge 4 commits into
mainfrom
ui_hibernate_slots

Conversation

@pjain1

@pjain1 pjain1 commented Sep 15, 2026

Copy link
Copy Markdown
Member

New projects now default to 2 production and development slots, including development CLI builds. Project admins can change allocations in one Deployment slots panel under Status → Branches. A single Save request updates only the changed fields, with positive-integer validation, resource previews, quota errors, and refreshed project/deployment data.

The Branches page stays accessible when cloud editing is disabled; development slot controls and the CLI branch-creation hint are hidden in that case. The Overview shortcut points to Branches. Hibernation remains in Settings → General, with permission/pending guards and refreshed project lists after success.

Slot-only edits reconcile deployments in the affected environment: production changes leave development untouched, and development changes leave production untouched. Shared project configuration changes still reconcile all deployments, and hibernated deployments stay stopped. The slots panel uses a red warning boundary and explains that changing slots reconciles the project and may restart deployments.

Admin unit and component tests now run in CI, including on shared web code or dependency changes. Vitest discovery is restricted to source tests so Playwright specs are excluded; existing bookmark and model-action fixtures are updated to match current behavior.

Validation: all 360 web-admin tests and 2,855 web-common tests pass (one shared suite skipped). All 14 slot reconciliation regression cases pass with the Go race detector. Targeted ESLint passes with existing warnings. Docker-backed server integration tests were not run locally.

Screenshot 2026-09-15 at 10 08 44 PM

Checklist:

  • Covered by tests
  • Ran it and it works as intended
  • Reviewed the diff before requesting a review
  • Checked for unhandled edge cases
  • Linked the issues it closes
  • Checked if the docs need to be updated. If so, create a separate Linear DOCS issue
  • Intend to cherry-pick into the release branch
  • I'm proud of this work!

@AdityaHegde AdityaHegde left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving from code POV.

But UX wise it feels like the slots settings is just crammed in and feels out of place in Status tab. Should ideally be in Settings tab. But up to @nishantmonu51 to have the final say on UX.

@nishantmonu51 nishantmonu51 added Type:Feature New feature request Team:Platform Platform Working Group Size:L Large change: 500-1,999 lines labels Sep 16, 2026

@nishantmonu51 nishantmonu51 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

web-admin's test:unit (web-admin/package.json:10) is not invoked by any workflow. .github/workflows/web-test-unit-tests.yml:37-39 triggers on web-admin/** but runs only npm run test -w web-common, so the new project-resources.component.spec.ts and the test.projects block never execute in CI.

Separately, the unit project at web-admin/vite.config.ts:12-25 sets no include, so vitest run still collects the Playwright specs in web-admin/tests/*.spec.ts; 13 of them fail with Cannot find package '@rilldata/web-common/tests/...'. Adding include: ["src/**/*.spec.ts"] and wiring test:unit -w web-admin into the workflow would make both halves real.


admin/projects.go:200 adds oldProj.DevSlots != opts.DevSlots to impactsDeployments, routing to UpdateDeploymentsForProject (admin/deployments.go:139) -> UpdateDeployment (admin/deployments.go:97), which resets the desired status and enqueues a reconcile for every deployment regardless of environment. A dev-slots-only edit therefore restarts prod too. The TODO at admin/projects.go:250 documents this, but it is worth confirming it is acceptable before shipping.

@pjain1
pjain1 requested a balanced review from Copilot September 17, 2026 12:19

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Size:L Large change: 500-1,999 lines Team:Platform Platform Working Group Type:Feature New feature request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants