Skip to main content
← Back to list
01Issue
FeatureOpenSwamp Club
AssigneesNone

Relationships

#1525 Harden queue claim semantics: atomic claims + status-guarded markDelivered/markFailed across app queues

Opened by adam · 8/4/2026

PR #1038's CI review flagged (MEDIUM, non-blocking) that the find-then-updateMany claim pattern shared by MongoResendContactQueue, MongoSystemMessageQueue, and MongoFeedJudgeQueue lets two pods claim the same entry in a narrow race, and that markDelivered/markFailed don't filter on current status — so a loser's markFailed can overwrite a winner's delivered status and cause a spurious retry. All consumers are idempotent so the system converges, but a hardening pass should (a) claim per-doc atomically (findOneAndUpdate loop or claim-token updateMany + re-read, as services/telemetry/lib/watcher.ts already does) and (b) add status: "processing" guards to the mark* filters. One pass across all three app queues plus their shared tests.

02Bog Flow
OPENTRIAGEDIN PROGRESSSHIPPED

Open

8/4/2026, 11:13:25 PM

No activity in this phase yet.

03Sludge Pulse

Sign in to post a ripple.