Skip to content
Mike Perham edited this page Jun 10, 2021 · 2 revisions

Faktory's MUTATE API allows you to scan the sorted sets within Redis (retries, scheduled, dead) and take action (delete, enqueue, kill) on entries.

require 'faktory/mutate'

cl = Faktory::Client.new
cl.discard(Faktory::RETRIES) do |filter|
  filter.with_type("QuickBooksSyncJob")
  filter.matching("*uid:12345*"))
end

The argument to matching is a low-level regexp that Redis runs against every job payload; be careful it will match against the actual bytes of the JSON-serialized payload.

Clone this wiki locally