-
Notifications
You must be signed in to change notification settings - Fork 1.1k
fix(coderd/database): improve task status in tasks_with_status view #20683
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
b7a6a36 to
ba00051
Compare
ba00051 to
136839b
Compare
ssncferreira
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🧊
Just a comment about adding workspace_agent.lifecycle_state and workspace_app.health to the final SELECT, if you think that would make sense 🙂
coderd/database/migrations/000397_update_task_status_view.up.sql
Outdated
Show resolved
Hide resolved
7c5698c to
ea8080a
Compare
ssncferreira
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM ![]()
This change restructures the
tasks_with_statusview query to:status_debugcolumn to better understand the outcomebool_or,bool_andwhich are aggregate functions that did not actually have serve a purpose (each join is 0-1 rows)start_timeoutandstart_errorwere omittedunknown, now there are explicit (I initially considerederror, could go either way)