mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
feat: add provisioning timings to understand slow build times (#14274)
This commit is contained in:
@@ -144,3 +144,15 @@ WHERE
|
||||
updated_at < $1
|
||||
AND started_at IS NOT NULL
|
||||
AND completed_at IS NULL;
|
||||
|
||||
-- name: InsertProvisionerJobTimings :many
|
||||
INSERT INTO provisioner_job_timings (job_id, started_at, ended_at, stage, source, action, resource)
|
||||
SELECT
|
||||
@job_id::uuid AS provisioner_job_id,
|
||||
unnest(@started_at::timestamptz[]),
|
||||
unnest(@ended_at::timestamptz[]),
|
||||
unnest(@stage::provisioner_job_timing_stage[]),
|
||||
unnest(@source::text[]),
|
||||
unnest(@action::text[]),
|
||||
unnest(@resource::text[])
|
||||
RETURNING *;
|
||||
|
||||
Reference in New Issue
Block a user