mirror of
https://github.com/hibiken/asynq.git
synced 2024-12-26 07:42:17 +08:00
(cli): Update queue inspect cmd to show # of groups and aggregating tasks
This commit is contained in:
parent
47af17cfb4
commit
01eeb8756e
@ -145,12 +145,13 @@ func printQueueInfo(info *asynq.QueueInfo) {
|
||||
bold.Println("Queue Info")
|
||||
fmt.Printf("Name: %s\n", info.Queue)
|
||||
fmt.Printf("Size: %d\n", info.Size)
|
||||
fmt.Printf("Groups: %d\n", info.Groups)
|
||||
fmt.Printf("Paused: %t\n\n", info.Paused)
|
||||
bold.Println("Task Count by State")
|
||||
printTable(
|
||||
[]string{"active", "pending", "scheduled", "retry", "archived", "completed"},
|
||||
[]string{"active", "pending", "aggregating", "scheduled", "retry", "archived", "completed"},
|
||||
func(w io.Writer, tmpl string) {
|
||||
fmt.Fprintf(w, tmpl, info.Active, info.Pending, info.Scheduled, info.Retry, info.Archived, info.Completed)
|
||||
fmt.Fprintf(w, tmpl, info.Active, info.Pending, info.Aggregating, info.Scheduled, info.Retry, info.Archived, info.Completed)
|
||||
},
|
||||
)
|
||||
fmt.Println()
|
||||
|
Loading…
Reference in New Issue
Block a user