Skip to content
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

refactor: extract fs lock into go-fs-lock #4631

Merged
merged 2 commits into from
Mar 30, 2018

Conversation

dignifiedquire
Copy link
Member

@dignifiedquire dignifiedquire commented Jan 31, 2018

Need this code in another place, so I figured I pull it out into its own thing to share the code.

Requires ipfs/go-fs-lock#1 to be merged and published to gx.

@ghost ghost assigned dignifiedquire Jan 31, 2018
@ghost ghost added the status/in-progress In progress label Jan 31, 2018
@dignifiedquire dignifiedquire changed the title [WIP] refactor: extract fs lock into go-fs-lock refactor: extract fs lock into go-fs-lock Feb 7, 2018
@whyrusleeping
Copy link
Member

@dignifiedquire will need to rebase, package.json funtimes and all

@dignifiedquire
Copy link
Member Author

@whyrusleeping fixed

mfsr "github.com/ipfs/go-ipfs/repo/fsrepo/migrations"
serialize "github.com/ipfs/go-ipfs/repo/fsrepo/serialize"
dir "github.com/ipfs/go-ipfs/thirdparty/dir"
lockfile "gx/ipfs/QmTAQSKWDGV7MpNGZrcj9gzbBLk3vG77EcBkCQtPphCknP/go-fs-lock"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since I'm the extracting expert now, I should point out that this import should be grouped with the other gx'ed ones...

@Kubuxu Kubuxu added RFM and removed status/in-progress In progress labels Mar 9, 2018
@Kubuxu Kubuxu added this to the go-ipfs 0.4.15 milestone Mar 9, 2018
@ghost ghost assigned hsanjuan Mar 13, 2018
@ghost ghost added the status/in-progress In progress label Mar 13, 2018
@hsanjuan
Copy link
Contributor

I have bubbled the last version of go-fs-lock here (ipfs/go-fs-lock#3). I rebased on master, removed lock from package.json which was not used. The newer version should reduce the number of duplicate gx imports.

@hsanjuan
Copy link
Contributor

Did github stop at some point dismissing approvals when someone pushes new changes?

@dignifiedquire
Copy link
Member Author

Did github stop at some point dismissing approvals when someone pushes new changes?

it's a project specific setting you can change

@Kubuxu
Copy link
Member

Kubuxu commented Mar 13, 2018

LGTM and RFM.

@Kubuxu Kubuxu removed the status/in-progress In progress label Mar 13, 2018
@@ -297,7 +301,7 @@ func Init(repoPath string, conf *config.Config) error {
// process. If true, then the repo cannot be opened by this process.
func LockedByOtherProcess(repoPath string) (bool, error) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@whyrusleeping any real reason to check this early (it's racy anyways)? We could get rid of the fs-repo-lock package entirely (depending directly on go4's lock) if we simply took the lock file when needed instead of checking.

dignifiedquire and others added 2 commits March 29, 2018 12:22
License: MIT
Signed-off-by: dignifiedquire <dignifiedquire@gmail.com>
License: MIT
Signed-off-by: Jakub Sztandera <kubuxu@protonmail.ch>
@ghost ghost assigned Stebalien Mar 29, 2018
@ghost ghost added the status/in-progress In progress label Mar 29, 2018
@Stebalien Stebalien removed the status/in-progress In progress label Mar 29, 2018
@whyrusleeping whyrusleeping merged commit fa9489e into master Mar 30, 2018
@whyrusleeping whyrusleeping deleted the refactor/extract-fs-lock branch March 30, 2018 00:59
@djdv djdv mentioned this pull request Apr 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants