-
-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
guarantee mutually exclusive access to persisted state #358
Comments
Yeah we have been using this. do we want to continue? is there a better word? The proposal SGTM. 👍 |
Repo SGTM |
@maybebtc , 👍 good points here. It seems that currently @jbenet is locking a token file Are you suggesting locking everything within BTW, evidently using |
using one mechanism to manage all items in IPFS_DIR |
@briantigerchow i believe this can be closed now? reopen if not. |
As part of its normal operation, IPFS persists these items to disk:
IPFS_DIR/logs/
IPFS_DIR/config
IPFS_DIR/datastore/
Collectively, we refer to these as the
repo
.issue
We wish to ensure that access to these resources is granted to just one process at a time.
While different mechanisms could be used to enforce mutually-exclusive access for each of the three resources, it may be simpler to provide a common mechanism to cover them all.
proposal
A good first step is to repurpose the
daemon.Lock
(lock file) as arepo.Lock
or aresource.Lock
.NB: This doesn't provide guarantees against callers who sidestep the Lock and go after the resources directly.
The text was updated successfully, but these errors were encountered: