Skip to content

Commit

Permalink
fix(api): metrics on jobs (#3273)
Browse files Browse the repository at this point in the history
  • Loading branch information
yesnault committed Aug 30, 2018
1 parent a4075ba commit fd3b4f2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion engine/api/metrics/metrics.go
Expand Up @@ -69,7 +69,7 @@ func Initialize(c context.Context, DBFunc func() *gorp.DbMap, instance string) {
count(DBFunc(), nbWorkflowRuns, "SELECT MAX(id) FROM workflow_run")
count(DBFunc(), nbWorkflowNodeRuns, "SELECT MAX(id) FROM workflow_node_run")
count(DBFunc(), nbMaxWorkersBuilding, "SELECT COUNT(1) FROM worker where status = 'Building'")
count(DBFunc(), nbJobs, "SELECT MAX(id) FROM workflow_node_run_job_info")
count(DBFunc(), nbJobs, "SELECT COUNT(1) FROM (SELECT distinct(workflow_node_run_job_id) from workflow_node_run_job_info group by workflow_node_run_job_id) AS temp")

now := time.Now()
now10s := now.Add(-10 * time.Second)
Expand Down

0 comments on commit fd3b4f2

Please sign in to comment.