feat(openchoreo): show suspended state in the deployment pipeline#667
feat(openchoreo): show suspended state in the deployment pipeline#667isala404 wants to merge 1 commit into
Conversation
A component whose workload is scaled to zero showed as "Active" in the deployment pipeline, which is misleading. Core already reports the suspended state on the ReleaseBinding's ResourcesReady condition (reason ReadyWithSuspendedResources), but the backend only read the Ready condition. The backend now reads that reason on a Ready binding and passes it through, and the pipeline renders a "Suspended" badge instead of "Active". Signed-off-by: Isala Piyarisi <mail@isala.me>
|
Warning Review limit reached
Next review available in: 28 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (7)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
What
A component whose workload is scaled to zero showed as "Active" in the deployment pipeline, which is misleading. This adds a distinct "Suspended" state so it reads correctly.
How
Core already reports the suspended state on the ReleaseBinding's ResourcesReady condition (reason
ReadyWithSuspendedResources), but the backend transformer only looked at the Ready condition, which stays Ready for a scaled-to-zero workload. The transformer now also checks ResourcesReady on a Ready binding and surfaces that reason, and the frontend maps it to a newsuspendedbadge variant labelled "Suspended".release-binding.tsreads the ResourcesReady reason on a Ready binding.useEnvironmentStatusVariant.tsmapsReadyWithSuspendedResourcesto asuspendedvariant.StatusBadge.tsxadds thesuspendedvariant (amber, matching the existing suspended styling in the resource tree).No core change is needed. The state is already aggregated onto the ReleaseBinding.
Testing
Unit tests added for the transformer, the status hook, and the badge. The data path was checked against a live cluster: a scaled-to-zero component's ReleaseBinding carries
ResourcesReady=ReadyWithSuspendedResources, which is what the backend now reads. Affected tests, lint, and prettier pass, and the touched files are type-clean.Part of #3104