peerstore: Peer record handling is not atomic in the on-disk peerstore
Open
Nobody has claimed this yet.
kind/bug
- Dominant language
- Go
- Stars
- 6.9k
- Forks
- 1.3k
- Avg merge
- 13d 21h
- Merged PRs (30d)
- 1
Description
We need to take a lock somewhere to ensure that multiple concurrent calls to `ConsumePeerRecord` don't interleave, leaving us with addresses from one, and the record from the other.
Contributor guide
No contributing guide indexed for this repository
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 at the on-disk peerstore implementation of ConsumePeerRecord and trace how concurrent calls update peer addresses and records. Determine where the operation can be serialized, then verify that concurrent calls cannot leave addresses from one record paired with the other record.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100