Coordinated retry: a park timeout uses up the retry budget and cannot be told apart from a lost conflict
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 35/100
Research direction
Read src/database.ts around coordinatedRetry and transaction.cpp around the park-timeout default; also review the related issue #744. First decide which retry-budget behavior should apply, then determine how to expose a distinguishable timeout signal. Done means the chosen behavior and signal are implemented and tested, but this issue does not name specific test files.
Written by the indexing model from the issue text.
Description
Coordinated retry: a park timeout uses up the retry budget and cannot be told apart from a lost conflict
What happens
coordinatedRetry in src/database.ts (around lines 1175-1220 on main 1b165e094) parks a conflicting transaction until the lock holder wakes it, or until the park timeout fires. The default timeout is 5000 ms (transaction.cpp, around line 252). Both outcomes come back as RETRY_NOW, and both use up one of the maxRetries attempts (default 3).
Two results:
- Budget. A holder that is slow but alive, for example a long write transaction holding the record for more than about 15 s, uses up all retries through timeouts alone. The waiter then fails with
did not commit after N coordinated retries, although no conflict was ever lost. - Signal. No event, error code or error detail says that the retries ended through park timeouts rather than through repeated lost conflicts. A grep of
src/*.tsfinds no park-timeout event. An operator who sees the error cannot tell "the holder is stuck" from "the record is under heavy contention".
Decision needed
Choose which of these should happen:
- (a) Timeout wakes still count against
maxRetries, but the final error states how many attempts ended in a park timeout. This is the smallest change. - (b) Timeout wakes get their own budget, or a total wall-clock deadline, separate from conflict retries.
- (c) Keep the current behavior and document it next to
maxRetriesand the park timeout option.
Whatever is chosen, emit a distinguishable signal (an event or error property) when a park times out, so Harper can log it.
Related
- #744 added the park timeout (merged 2026-08-25).
- The holder-leak shape that makes long parks likely is harper#2001.
- Wake-callback deregistration (
LockTracker::wakeCallbackshas no removal API) is being handled separately as a dispatch fix.
- Dominant language
- C++
- Stars
- 24
- Forks
- 3
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 49
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from HarperFast/rocksdb-js
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
HarperFast/rocksdb-js#945 ·
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 55/100
HarperFast/rocksdb-js#956 ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
HarperFast/rocksdb-js#955 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 45/100
HarperFast/rocksdb-js#952 ·
Maintainers usually reply within 1 day
-
Difficulty 4/5 1-2 days Newbie friendliness 45/100
HarperFast/rocksdb-js#946 ·
Maintainers usually reply within 1 day
All issues in HarperFast/rocksdb-js
Similar issues
-
Remove source files from packaging for deb, zip, etcPossibly taken A pull request linked to this issue is open or already merged. Open
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
OpenSpace/OpenSpace#4353 · 1 comment ·
Maintainers usually reply within 5 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
justcallmekoko/ESP32Marauder#1656 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
Decompiler: convertCharRef() in xml.y overflows its int4 accumulator on long character referencesPossibly taken @kaayzouee claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
NationalSecurityAgency/ghidra#10009 ·
Maintainers usually reply within 2 days