Skip to content

feat: show pool reason on dashboard and droplet detail#501

Merged
MichielDean merged 1 commit into
mainfrom
feat/pool-reason-on-dashboard
May 10, 2026
Merged

feat: show pool reason on dashboard and droplet detail#501
MichielDean merged 1 commit into
mainfrom
feat/pool-reason-on-dashboard

Conversation

@MichielDean
Copy link
Copy Markdown
Owner

Summary

  • Pooled droplets in the dashboard are now clickable — clicking expands a row to show the pool reason inline
  • Droplet detail page now shows a "Pool Reason" section (red-bordered callout) for pooled droplets
  • Adds GetPoolReasons() and GetPoolReason() methods to the cistern client, querying the events table for pool event payloads
  • DashboardData now includes pool_reasons: Record<string, string> mapping pooled droplet IDs to their reasons
  • PooledSection passes poolReasons in, DropletRow gains onClick and expanded props for interactive expansion
  • Droplet IDs in DropletRow are now clickable links to the detail page (navigate via react-router-dom)
  • Single-droplet API (GET /api/droplets/{id}) now includes pool_reason field for pooled droplets
  • All existing tests updated for new pool_reasons field

Changed files

  • internal/cistern/client.goGetPoolReasons(), GetPoolReason() methods
  • cmd/ct/dashboard.goPoolReasons in DashboardData, populated in fetchDashboardData
  • cmd/ct/dashboard_web.gohandleGetDroplet injects pool_reason for pooled droplets
  • web/src/api/types.tspool_reasons on DashboardData, pool_reason on Droplet
  • web/src/pages/Dashboard.tsxPooledSection with expandable rows showing reasons
  • web/src/pages/DropletDetail.tsx — Pool Reason section for pooled droplets
  • web/src/components/DropletRow.tsx — Clickable ID links, onClick/expanded props
  • web/src/__tests__/ — Updated mock data with pool_reasons

Clickable pooled rows expand to show the reason; droplet detail shows
a dedicated Pool Reason section for pooled droplets. Adds
GetPoolReason/GetPoolReasons to the cistern client and includes
pool_reasons in the dashboard SSE stream.
@MichielDean MichielDean merged commit dd49eee into main May 10, 2026
3 checks passed
@MichielDean MichielDean deleted the feat/pool-reason-on-dashboard branch May 10, 2026 04:15
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