Differentiating between waiting on dependencies and workers

This commit is contained in:
Laszlo Fogas
2019-07-09 16:23:56 +02:00
parent 3c50918eb5
commit bb941c8b83
5 changed files with 117 additions and 36 deletions

View File

@@ -27,6 +27,7 @@ func Test_QueueInfo(t *testing.T) {
"stats": {
"worker_count": 3,
"pending_count": 0,
"waiting_on_deps_count": 0,
"running_count": 1,
"completed_count": 0
},

View File

@@ -150,10 +150,11 @@ type (
// Info provides queue stats.
Info struct {
Stats struct {
Workers int `json:"worker_count"`
Pending int `json:"pending_count"`
Running int `json:"running_count"`
Complete int `json:"completed_count"`
Workers int `json:"worker_count"`
Pending int `json:"pending_count"`
WaitingOnDeps int `json:"waiting_on_deps_count"`
Running int `json:"running_count"`
Complete int `json:"completed_count"`
} `json:"stats"`
Paused bool `json:"paused,omitempty"`
}