Queue storage: an ambiguous receipt claim can pin a slot's rescue cursor

Aperta
#693 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
48/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
postgresql, rust
Ambito
backend, databases

Direzione di ricerca

Read the receipt rescue cursor logic and the stale-heartbeat and deadline receipt sweeps, then inspect the regression tests for receipt mode and lease_claim_receipts. Start by tracing how an ambiguous claim affects cursor advancement. Add a test with more than 10,000 stale claims behind one ambiguous claim in a single slot; done means later claims are reached while the ambiguous claim is still reported.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

In receipt mode, one stale claim that rescue cannot settle can stop rescue in that claim slot from reaching later stale claims.

Rescue skips an attempt whose retained ready bodies are ambiguous, logs it, and leaves the claim open. The slot's receipt-rescue cursor only advances past claims that are closed, lease-managed, or closed by the current statement, so the cursor stays on the skipped claim. Each pass scans at most RECEIPT_RESCUE_CURSOR_SCAN_LIMIT (10,000) claims from the cursor, so stale claims more than 10,000 positions after it in the same slot are never reached. The open claim also keeps the slot from being pruned. The stale-heartbeat and deadline receipt sweeps both have this shape.

The lease-plane equivalent, where ambiguous attempts filled the frozen 500-row selection, is fixed in #691. This is the receipt-plane remainder. It is most likely with legacy claims that have no emitted-lane evidence.

Possible directions: advance the cursor past attempts that the current pass has excluded as ambiguous, keeping a separate record so they're still reported; or add a bounded side scan past the pinned position. A regression test needs more than the scan limit of stale claims behind one ambiguous claim in a single slot, with lease_claim_receipts enabled.

Lingua principale
Rust
Stelle
37
Fork
8
Merge medio
14h 16m
PR unite (30g)
244

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di hardbyte/awa

Tutte le issue di hardbyte/awa

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.