diff --git a/tools/asynqmon/cmd/ls.go b/tools/asynqmon/cmd/ls.go index e503538..f9cfb55 100644 --- a/tools/asynqmon/cmd/ls.go +++ b/tools/asynqmon/cmd/ls.go @@ -20,10 +20,10 @@ var validArgs = []string{"enqueued", "inprogress", "scheduled", "retry", "dead"} var lsCmd = &cobra.Command{ Use: "ls", Short: "lists queue contents", - Long: `The ls command lists all tasks from the given queue in a table format. + Long: `The ls command lists all tasks from the specified queue in a table format. -The command takes one argument which specifies the queue. The value -for the argument should be one of "enqueued", "inprogress", "scheduled", +The command takes one argument which specifies the queue to inspect. The value +of the argument should be one of "enqueued", "inprogress", "scheduled", "retry", or "dead". Example: asynqmon ls dead`, @@ -64,7 +64,7 @@ func ls(cmd *cobra.Command, args []string) { case "dead": listDead(r) default: - fmt.Printf("error: `asynqmon ls ` only accepts %v as the argument for queue.\n", validArgs) + fmt.Printf("error: `asynqmon ls ` only accepts %v as the argument.\n", validArgs) return } } diff --git a/tools/asynqmon/cmd/root.go b/tools/asynqmon/cmd/root.go index 49b2ea1..9bc08ac 100644 --- a/tools/asynqmon/cmd/root.go +++ b/tools/asynqmon/cmd/root.go @@ -19,12 +19,13 @@ var db int var rootCmd = &cobra.Command{ Use: "asynqmon", Short: "A monitoring tool for asynq queues", - Long: `TODO(hibiken): A longer description that spans multiple lines and likely contains -examples and usage of using your application. For example: + Long: `Asynqmon is a CLI tool to inspect and monitor queues managed by asynq package. -Cobra is a CLI library for Go that empowers applications. -This application is a tool to generate the needed files -to quickly create a Cobra application.`, +Asynqmon has a few subcommands to show the current state of the queues, while others were +used to make manual changes to the queues. Monitoring commands can be used in conjunction +with the "watch" command to continuously run the command at a certain interval. + +Example: watch -n 5 asynqmon stats`, // Uncomment the following line if your bare application // has an action associated with it: // Run: func(cmd *cobra.Command, args []string) { },