bullmq-dash 0.3.0 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +40 -21
  2. package/dist/index.js +1548 -1430
  3. package/package.json +4 -1
package/README.md CHANGED
@@ -7,10 +7,11 @@ Terminal UI dashboard for [BullMQ](https://bullmq.io/)
7
7
  ## Features
8
8
 
9
9
  - **Real-time monitoring** - Watch queues and jobs update live with configurable polling
10
- - **Queue overview** - View all BullMQ queues with job counts and status
10
+ - **Queue overview** - View all BullMQ queues with job counts, failure counts, and task-size sorting
11
11
  - **Job inspection** - Browse jobs by status, view details, data, and error stacktraces
12
+ - **Failed-job recovery** - Find failed jobs quickly and retry one job by ID or a filtered batch
12
13
  - **Scheduler monitoring** - View Job Schedulers (repeatable jobs) with patterns, iterations, and job history
13
- - **Job management** - Add, cancel, delete, and retry jobs directly from the dashboard
14
+ - **Job management** - Delete jobs from the TUI and retry failed jobs from headless mode
14
15
  - **Global metrics** - Track enqueue/dequeue rates across all queues
15
16
 
16
17
  ## Requirements
@@ -85,6 +86,29 @@ bullmq-dash --tui --redis-url <redis-url> --queues email,notifications,payments
85
86
  bullmq-dash --tui --redis-url <redis-url> --poll-interval 5000
86
87
  ```
87
88
 
89
+ ### Headless Queue Operations
90
+
91
+ Headless commands print JSON by default, so they are safe to pipe through `jq`
92
+ or run from automation.
93
+
94
+ ```bash
95
+ # Rank queues by task size, largest first
96
+ bullmq-dash queues list --redis-url <redis-url> --sort-by task-size
97
+
98
+ # Rank queues by failed jobs
99
+ bullmq-dash queues list --redis-url <redis-url> --sort-by failed
100
+
101
+ # Find failed jobs in a queue
102
+ bullmq-dash jobs failed email --redis-url <redis-url>
103
+
104
+ # Preview retrying one failed job, then run it
105
+ bullmq-dash jobs retry email --redis-url <redis-url> --job-id 42 --dry-run
106
+ bullmq-dash jobs retry email --redis-url <redis-url> --job-id 42 --yes
107
+
108
+ # Preview a filtered batch retry
109
+ bullmq-dash jobs retry email --redis-url <redis-url> --job-state failed --since 1h --dry-run
110
+ ```
111
+
88
112
  ## Connection Profiles
89
113
 
90
114
  Save Redis connections as named profiles so you don't have to remember (or paste)
@@ -98,14 +122,15 @@ and reference it with `--profile`:
98
122
  "local": { "redis": { "url": "<local-redis-url>" } },
99
123
  "prod": {
100
124
  "redis": { "url": "${REDIS_PROD_URL}" },
101
- "queues": ["payments", "notifications"]
125
+ "queues": ["payments", "notifications"],
126
+ "cacheTtlMs": 86400000
102
127
  },
103
128
  "upstash": { "redis": { "url": "${REDIS_URL}" } }
104
129
  }
105
130
  }
106
131
  ```
107
132
 
108
- Each profile carries a single `redis.url`. The `${VAR}` form interpolates an environment variable as the **whole value** (partial substitution is intentionally not supported), which pairs nicely with managed providers (Upstash, Heroku Redis, Render, Railway, Fly) that hand you a single `REDIS_URL` env var. Prefer environment-backed profile values for authenticated Redis URLs.
133
+ Each profile carries a single `redis.url`. `cacheTtlMs` controls the SQLite observation-cache TTL and defaults to 24 hours. The `${VAR}` form interpolates an environment variable as the **whole value** (partial substitution is intentionally not supported), which pairs nicely with managed providers (Upstash, Heroku Redis, Render, Railway, Fly) that hand you a single `REDIS_URL` env var. Prefer environment-backed profile values for authenticated Redis URLs.
109
134
 
110
135
  ```bash
111
136
  # Connect using the default profile (defaultProfile field above)
@@ -155,6 +180,7 @@ without auth — keep passwords out of the file itself.
155
180
  | `Enter` | View job details |
156
181
  | `d` | Delete selected job |
157
182
  | `r` | Refresh data |
183
+ | `s` | Cycle queue sorting |
158
184
  | `q` / `Ctrl+C` | Quit |
159
185
 
160
186
  ### Job Status Filter
@@ -225,7 +251,7 @@ bun run start
225
251
  # Audit the immutable 0.2.7 Socket target (historical evidence)
226
252
  bun run security:audit-0.2.7
227
253
 
228
- # Score the configured package version after it is published
254
+ # Optional manual Socket score for an already-published version
229
255
  bun run security:score
230
256
 
231
257
  # Verify forbidden local-only files are ignored and not tracked
@@ -234,7 +260,7 @@ bun run security:verify-source-control
234
260
  # Verify Bun package manager pinning, bun.lock tracking, and frozen installs
235
261
  bun run security:verify-lockfile
236
262
 
237
- # Verify CI/publish workflows pin actions, lock down releases, and score after publish
263
+ # Verify CI/publish workflows pin actions and lock down releases
238
264
  bun run security:verify-workflows
239
265
 
240
266
  # Verify source import policy, npm tarball contents, and stripped publish manifest
@@ -260,26 +286,19 @@ or gitleaks), enforces packed-tarball size and entry-count limits, and
260
286
  verifies the stripped publish manifest. Note: `ioredis` remains a transitive
261
287
  dependency through `bullmq`; the policy blocks _direct_ imports only.
262
288
 
263
- `bun run security:score` runs the Socket package score against the version in
264
- `package.json` (must already be published to npm). It compares the alert set
265
- against an accepted-alert allowlist that includes the capabilities a Redis
266
- monitoring tool legitimately needs (`networkAccess`, `urlStrings`,
267
- `filesystemAccess`, `envVars`), Socket's transient `recentlyPublished` window,
268
- and the transitive alert types present in the `bullmq` and `@opentui/core`
269
- graphs. The gate exits nonzero only when an alert type appears outside that set,
270
- which surfaces real regressions from dependency updates without paging on every
271
- publish.
289
+ `bun run security:score` is an optional manual audit for a version that already
290
+ exists on npm. It compares the Socket alert set against the accepted-alert
291
+ allowlist, but it is intentionally not part of the publish workflow because
292
+ Socket scoring can lag or fail after npm accepts the immutable package version.
272
293
 
273
294
  `bun run security:verify-workflows` rejects mutable GitHub Action refs,
274
295
  `pull_request_target` triggers, and direct `${{ github.event.* }}` interpolation
275
296
  in workflow commands. It also verifies CI and publish workflows run the
276
297
  source-control, lockfile, workflow, and package policy verifiers, CI uses
277
- read-only permissions, and the npm publish workflow scopes secrets to approved
278
- step env entries, is release-only, runs the source-control, lockfile, workflow,
279
- and package verifiers before publishing, uses least privilege, keeps npm
280
- lifecycle scripts enabled, publishes with provenance, installs the Socket CLI by
281
- the configured exact version `1.1.94`, and runs the post-publish Socket score
282
- gate.
298
+ read-only permissions, and the npm publish workflow rejects publish secrets,
299
+ is release-only, runs the source-control, lockfile, workflow, and package
300
+ verifiers before publishing, uses least privilege, keeps npm lifecycle scripts
301
+ enabled, and publishes with provenance.
283
302
 
284
303
  `bun run security:verify-source-control` rejects tracked `.env` / `.envrc` /
285
304
  `.npmrc` files, build output, publish manifest backups, and generated package