oasisprotocol / oasisprotocol/oasis-core

go/worker/storage/committee: Delay fetching chunk when no peers available

Open Beginner friendly
#6,492 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
369
Forks
151
Avg merge
1d 3h
Merged PRs (30d)
6

Description

Hot loop caused the worker's checkpoint sync to become stuck:

{"caller":"checkpoint_sync.go:108","chunk":161,"err":"no peers given to service the request","level":"error","module":"worker/storage/committee","msg":"failed to fetch chunk from peers","runtime_id":"000000000000000000000000000000000000000000000000f80306c9858e7279","ts":"2026-04-06T15:12:28.315550177Z"}
....  repeat N times

Solution:

  • Add backoff/timeout or per-chunk backoff as suggested.
    • Lets keep it simple for the start and only have simple delay.
  • Fix defer in the for loop (resource leak).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with go/worker/storage/committee/checkpoint_sync.go, especially the hot loop around lines 90–113 and the backoff note near line 292. Reproduce or inspect the no-peer checkpoint-fetch path, then verify that fetching is delayed when no peers are available and that the defer in the loop no longer leaks resources.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
distributed-systems
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.