Ordered loader keeps no handle to release a failed request from before a cursor reset
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 35/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- typescript
- Ambito
- backend
Direzione di ricerca
Read packages/db/src/query/live/ordered-source-loader.ts, the acquisition release rules in ARCHITECTURE.md, and packages/db/tests/query/ordered-source-loader-state-oracle.test.ts. First add a failing named history with a page in flight, a truncate, a failed page request, and further truncates; track releases for that demand. Done means the witness establishes who owns the failed dead request’s lease and verifies each acquisition is released exactly once.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Summary
A review of #2194 reported a possible lease leak in OrderedSourceLoader (packages/db/src/query/live/ordered-source-loader.ts). No test reproduces it yet.
A request that the loader issued before a cursor reset is dead after the reset. If a dead request succeeds, the loader records its lease in settledFiniteAcquisitions and later retires it. If a dead request fails, the failure handler returns before it records the lease in failedAcquisitions. Then the loader keeps no handle that can release the lease.
Expected
The loader or the truncate replay releases each acquisition exactly once (ARCHITECTURE.md, acquisition release rules).
Possible result
The subscription keeps the failed demand for replay, and the replay acquires it again. Nothing releases that demand until the subscription ends, so each later truncate replays it again. This causes more provider load and a leaked lease.
Next step
Before a change, add a witness that fails. The request-authority oracle in packages/db/tests/query/ordered-source-loader-state-oracle.test.ts does not judge requests issued before a truncate, because the replay owns them. A witness must decide which component owns a failed dead request's lease. It can be a named history: a page in flight, a truncate, a failure of the page, and then more truncates. It counts the releases for that demand.
This issue was written by Isaac.
- Lingua principale
- TypeScript
- Stelle
- 4k
- Fork
- 277
- Merge medio
- 17h 40m
- PR unite (30g)
- 223
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di TanStack/db
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
I maintainer di solito rispondono entro 1 giorno
-
Garbage collection cleans up a collection while one of its transactions is still persistingForse già presa @Nabil372 l’ha presa 1 giorno fa. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 35/100
I maintainer di solito rispondono entro 1 giorno
-
persistedCollectionOptions without a schema can't be passed to createCollection (follow-up to #1452)Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
openremote/openremote#3487 · 1 commento ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
coollabsio/jean#867 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
ehmpathy/rhachet-roles-bhuild#616 ·
I maintainer di solito rispondono entro 1 giorno
-
📘 Docs supabase/cli
Difficoltà 2/5 1-3 ore Idoneità per principianti 83/100
I maintainer di solito rispondono entro 1 giorno
-
bug(cli): theme file home-directory check uses startsWith (sibling dirs pass, Windows casing fails)Apertaarea/core kind/bug priority/p2 status/bot-triaged
Difficoltà 2/5 1-3 ore Idoneità per principianti 79/100
google-gemini/gemini-cli#29955 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno