Class: Falqon::CLI::Clear

Inherits:
Base
  • Object
show all
Defined in:
lib/falqon/cli/clear.rb

Overview

Clear messages from a queue

Clearing a subqueue removes all messages and their data from the subqueue.

Usage:

falqon clear -q, --queue=QUEUE

Options:

-q, --queue=QUEUE                                           # Queue name
    [--pending], [--no-pending], [--skip-pending]           # Clear only pending messages
    [--processing], [--no-processing], [--skip-processing]  # Clear only processing messages
    [--dead], [--no-dead], [--skip-dead]                    # Clear only dead messages

If none of the --pending, --processing, --scheduled, or --dead options are specified, all messages are cleared.

Examples:

Clear all messages in a queue

$ falqon clear --queue jobs
Cleared 3 messages from queue jobs

Clear only pending messages

$ falqon clear --queue jobs --pending
Cleared 3 messages from queue jobs

Clear only processing messages

$ falqon clear --queue jobs --processing
Cleared 3 messages from queue jobs

Clear only scheduled messages

$ falqon clear --queue jobs --scheduled
Cleared 3 messages from queue jobs

Clear only dead messages

$ falqon clear --queue jobs --dead
Cleared 3 messages from queue jobs