-
-
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
Add flush command to ipfs files #2196
Conversation
} | ||
|
||
// take the lock and defer the unlock | ||
defer nd.Blockstore.PinLock()() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this notation is a bit hard to read and error prone. i think these may be better:
nd.Blockstore.PinLk.Lock()
defer nd.Blockstore.PinLk.Unlock()
// or
defer nd.Blockstore.PinLock().Unlock()
@whyrusleeping this looks good. is it safe ? |
@jbenet its too safe. I need to remove the pinning. |
ahhaahah |
279f9d9
to
41498e7
Compare
f02c5eb
to
49e72d5
Compare
alright, this is ready. most of the review is needed on the last commit, i ripped the mfs file apart into an 'inode' type object, and a 'file descriptor' type object. This makes working with file things much easier, and i've been meaning to do it for a long time. Things should be a little more performant, way more threadsafe, the files api stuff shouldnt hang for @diasdavid, and fuse should be much happier in general. |
From command info I can see that it causes changes not to be flushed to disk. Wouldn't it be better to call it |
@Kubuxu the default is that changes are flushed to disk. the existing |
Ahh, ok. Sorry for that. |
@Kubuxu no worries, must be a documentation issue, what can i change to make that more clear? |
Just this wording is unfortunate. It suggests that just |
@Kubuxu there, that seems a little less confusing to me |
License: MIT Signed-off-by: Jeromy <[email protected]>
License: MIT Signed-off-by: Jeromy <[email protected]>
License: MIT Signed-off-by: Jeromy <[email protected]>
License: MIT Signed-off-by: Jeromy <[email protected]>
License: MIT Signed-off-by: Jeromy <[email protected]>
License: MIT Signed-off-by: Jeromy <[email protected]>
License: MIT Signed-off-by: Jeromy <[email protected]>
3deb40e
to
965fab4
Compare
…them License: MIT Signed-off-by: Jeromy <[email protected]>
License: MIT Signed-off-by: Jeromy <[email protected]>
965fab4
to
c47e12e
Compare
@RichardLitt adding 'ipfs files flush' in this PR. |
Add flush command to ipfs files
Thanks @whyrusleeping. Noted in ipfs-inactive/http-api-spec#57 |
No description provided.