Nick Craig-Wood
3fb4fe31d2
vfs: make sure write only handles never truncate files they shouldn't
2017-11-20 19:42:25 +00:00
Nick Craig-Wood
76b151984c
vfs: cache the size of the object in the read handle
2017-11-20 17:57:13 +00:00
Nick Craig-Wood
f0ed384786
cache: fix default setting for warmup_age
2017-11-20 14:39:12 +00:00
Nick Craig-Wood
f80f7a0509
cache: use fs.CacheDir to make the default directory for the cache
...
NB this changes the default dir for the cache
2017-11-20 14:38:28 +00:00
Nick Craig-Wood
af50f31f7d
mounttest: wait for Release after every Read to stop using in use files under Windows
2017-11-20 12:46:24 +00:00
Nick Craig-Wood
8e2213fbbd
local: add error message for cross file system moves
2017-11-20 12:46:24 +00:00
Nick Craig-Wood
085c690798
build: add in 64bit path for WinFSP headers
2017-11-20 12:46:24 +00:00
Nick Craig-Wood
2b666187a6
cmount: disable tests on windows + race detector
...
These either hang or produce incorrect results for reasons I haven't
worked out yet.
2017-11-20 12:46:24 +00:00
Nick Craig-Wood
00b46a8b96
mounttest: wait for files to disappear from the directory listing
2017-11-20 12:46:24 +00:00
Nick Craig-Wood
b21f227bd3
mounttest: fix crash when FUSE not present
2017-11-20 12:46:24 +00:00
Nick Craig-Wood
e98e550021
mounttest: wait for all background Close/Release after writing a file
...
The filesystem does a certain amount of things asynchronously waiting
for the file to be released after writing it means everything should
be in a consistent state.
2017-11-20 12:46:23 +00:00
Nick Craig-Wood
60945d0a37
vfs: remove misleading comment
2017-11-20 12:46:23 +00:00
Nick Craig-Wood
b4083b4371
vfs: rename Fsync to Sync and implement Sync on Node and Handle
2017-11-20 12:46:23 +00:00
Nick Craig-Wood
eb3415db50
cmount: enable more tests for Windows
2017-11-20 12:46:23 +00:00
Nick Craig-Wood
9fbd8a6419
mounttest: fixes for running under Windows
...
* don't mount and unmount between cache runs - WinFSP doesn't suport it
* use OS paths for opening things
2017-11-20 12:46:23 +00:00
Nick Craig-Wood
9738f8532b
vfs: Add FlushDirCache method
2017-11-20 12:46:23 +00:00
Nick Craig-Wood
a5b034a992
vfs: add WaitForWriters to wait until all writers have finished
2017-11-20 12:46:23 +00:00
Nick Craig-Wood
321b6da7af
vfs: don't remove file from writers until it is transferred
...
This means that the list of active writers is up to date
2017-11-20 12:46:23 +00:00
Nick Craig-Wood
1b22ee5b93
vfs: fix error handling in openPending so it returns the correct error
2017-11-20 12:46:23 +00:00
Nick Craig-Wood
eab55ce882
vfs: add open files to directories
2017-11-20 12:46:23 +00:00
Nick Craig-Wood
61b6159a05
mount, cmount: add O_CREATE to Open calls since fuse doesn't seem to supply it
2017-11-20 12:46:22 +00:00
Nick Craig-Wood
c560017934
vfs: add Path method to Node and use it to stop reading nil DirEntry
...
All DirEntry calls now have been checked for nil or converted to use Path.
2017-11-20 12:46:22 +00:00
Nick Craig-Wood
7c3584f4e6
mountlib: wait for mountpoint to disappear under Windows
2017-11-20 12:46:22 +00:00
Nick Craig-Wood
981cfb1bec
mounttest: retry directory listings to account for slow updates on Windows
2017-11-20 12:46:22 +00:00
Nick Craig-Wood
992647b157
vfs: Don't error a r/w file open without cache; delay error until Read called
...
If we open a file for r/w without the cache we now always return a
handle and return an error if the file is ever read from. This fixes
incompatibility with cmount under windows.
2017-11-20 12:46:22 +00:00
Nick Craig-Wood
dec21ccf63
vfs, cmount: make truncate work properly in the presence or otherwise of open files
2017-11-20 12:46:22 +00:00
Nick Craig-Wood
94adf4f43b
cmount: translate FUSE open flags into OS flags
...
On Windows the fuse.O_* flags do not have the same values as the
os.O_* flags so translate between the two representations. They are
mostly the same which is why this hasn't caused a problem before.
2017-11-20 12:46:22 +00:00
Nick Craig-Wood
e7f2935333
vfs: decode flags in Open/OpenFile for debug
2017-11-20 12:46:22 +00:00
Nick Craig-Wood
f5f8c0c438
cmount: make Truncate call the correct Handle or Node method
2017-11-20 12:46:22 +00:00
Nick Craig-Wood
60cdcf784c
cmount: use -o atomic_o_trunc to make sure O_TRUNC is supplied to Open()
2017-11-20 12:46:22 +00:00
Nick Craig-Wood
57a5c67729
mounttest: run the tests for all 4 VFS cache modes
2017-11-20 12:46:21 +00:00
Nick Craig-Wood
d7908c06c9
mountlib: ensure we don't open files with read and write intent
2017-11-20 12:46:21 +00:00
Nick Craig-Wood
8951875c21
vfs,mount,cmount,mountlib: allow flags to be overriden by environment variables
2017-11-20 12:46:21 +00:00
Nick Craig-Wood
05a1e1532b
vfs,mount,cmount,serve: Add documentation for vfs caching modes
2017-11-20 12:46:21 +00:00
Nick Craig-Wood
7f20e1d7f3
vfs: add read write files and caching #711
...
This adds new flags to mount, cmount, serve *
--cache-max-age duration Max age of objects in the cache. (default 1h0m0s)
--cache-mode string Cache mode off|minimal|writes|full (default "off")
--cache-poll-interval duration Interval to poll the cache for stale objects. (default 1m0s)
2017-11-20 12:36:50 +00:00
Nick Craig-Wood
bb0ce0cb5f
vendor: vfs add vendor/github.com/djherbis/times
2017-11-20 12:36:50 +00:00
Nick Craig-Wood
e946a8eab0
fs: Add CacheDir config variable
2017-11-20 12:00:32 +00:00
Nick Craig-Wood
a0cfa0929b
vfs: remove un-needed (after introduction of rcat) createInfo struct
2017-11-20 12:00:32 +00:00
Nick Craig-Wood
3fb1e96988
vfs: factor Open logic from Dir.Create into vfs.OpenFile
2017-11-20 12:00:32 +00:00
Nick Craig-Wood
46947b3b9b
rcat: fix goroutine leak
...
This was leaking goroutines in the short file case beause it wasn't
calling Close() on the Account object. This became apparent when
testing with mount.
2017-11-20 12:00:32 +00:00
Nick Craig-Wood
de98e2480d
Add Jakub Tasiemski to contributors
2017-11-20 11:16:22 +00:00
Jakub Tasiemski
3cf7c61aa0
Add touch command - fixes #1594
2017-11-20 11:16:05 +00:00
Fabian Möller
d8b3bf014d
mount: use sdnotify to signal systemd the mount is ready
...
When the NOTIFY_SOCKET environment variable is set notify systemd after
the mount is ready.
2017-11-20 11:03:10 +00:00
Fabian Möller
0bfa29cbcf
vendor: add github.com/okzk/sdnotify
2017-11-20 11:03:10 +00:00
Nick Craig-Wood
6cc968b085
Add Fabian Möller to contributors
2017-11-19 22:14:33 +00:00
Fabian Möller
ce5b3a531d
crypt: implement DirChangeNotify
...
crypt now implements the DirChangeNotify if the wrapped FS provides it.
2017-11-19 20:09:52 +00:00
Fabian Möller
5acb6f47e7
mountlib: log when poll-interval is ineffective
...
Notify the user in case poll-interval is used on a unsupported remote
2017-11-19 20:08:14 +00:00
Nick Craig-Wood
409ba56fde
Add Iakov Davydov to contributors
2017-11-17 21:52:00 +00:00
Nick Craig-Wood
5d875e8840
Add Remus Bunduc to contributors
2017-11-17 21:52:00 +00:00
Iakov Davydov
429bb7e8b8
docs for --exclude-if-present
2017-11-17 21:51:11 +00:00