Can we bring back eager locking safely in the parallel iterators?
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 642
- Forks
- 70
- Avg merge
- 2d 13h
- Merged PRs (30d)
- 21
Description
We had to disable eagerly grabbing the graph locks in #2221 to fix the issue where having both reads and writes on the same thread pool would dead-lock.
The underlying issue is that the old implementation would grab the locks even before the corresponding task is actually running and hence the pool could be trying to run all write tasks while the read task that is later in the queue is blocking them.
Might be possible to have a custom parallel iterator implementation that only locks when actually executing the task.
Contributor 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.
Research direction
Start by reviewing the parallel iterator implementation and issue #2221 to understand why eager graph-lock acquisition caused mixed read/write deadlocks. Design and validate a custom iterator that acquires locks only when tasks execute, with completion demonstrated by avoiding the reported deadlock scenario.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- backend, databases, performance
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100