Skip to content

provider: resume reprovide operations #1159

@guillaumemichel

Description

@guillaumemichel

Current situtation

A fresh reprovide cycle starts as soon as the SweepingProvider is created.

This means that if the node has been providing (and reproviding) content, then is turned off (not just offline) for a few hours/days, and then is restarted, it will take up to reprovideInterval for all keys to be reprovided.

Ideal situation

We want a similar behaviour to when the provide goes offline, which is to keep track of regions that should have been reprovided but weren't because the node was offline, and reprovide them as fast as possible when the provider comes back online.

We need to write reprovide timestamps to a datastore, so that when the SweepingProvider is started it can look in the datastore for regions that haven't been provided since at least reprovideInterval and schedule them to be reprovided ASAP.

Metadata

Metadata

Labels

P1High: Likely tackled by core team if no one steps upeffort/daysEstimated to take multiple days, but less than a weekexp/expertHaving worked on the specific codebase is importantprovider

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions