Skip to content
This repository has been archived by the owner on Aug 2, 2021. It is now read-only.

check both local pinning and global pinning flags #2186

Open
mortelli opened this issue May 14, 2020 · 0 comments
Open

check both local pinning and global pinning flags #2186

mortelli opened this issue May 14, 2020 · 0 comments
Assignees
Labels
global pinning experimental implementation of global pinning

Comments

@mortelli
Copy link
Contributor

mortelli commented May 14, 2020

In the current global pinning implementation, a user can set both the GlobalPinner and EnablePinning flags separate and independently.

This won't cause the code to break, but it doesn't really make sense to set the GlobalPinner flag if EnablePinning is unset. This is because only locally pinned files should be able to be re-uploaded for repair.

Eventually, when the recovery mechanism is triggered, a global pinner will just fail to re-upload a file if its not pinned. This is part of the logic in the setReUpload function of the localstore package.

If the flags are checked against each other, we can avoid triggering some of these useless recovery processes.

Note, however, that we cannot avoid all of them: a node can have both flags set and still receive recovery requests for a file it does no longer pin, or never pinned in the first place.

@mortelli mortelli added the global pinning experimental implementation of global pinning label May 14, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
global pinning experimental implementation of global pinning
Projects
None yet
Development

No branches or pull requests

2 participants