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
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
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
c31556c6d1
vfs: Make sure all public methods are locked in Read and Write Handle
2017-11-04 10:24:10 +00:00
Nick Craig-Wood
2083ac6e2a
vfs: add ECLOSED and tidy errors
2017-11-04 10:24:10 +00:00
Nick Craig-Wood
22ee839d05
cmount,vfs: unify Read and Write handles and File and Dir where possible
2017-11-04 10:24:10 +00:00
Nick Craig-Wood
5634659ea3
mount,vfs: unify Read and Write handles in preparation for ReadWrite handles
2017-11-04 10:24:10 +00:00
Nick Craig-Wood
e18122e88b
vfs: add tests and subsequent fixes
...
* Tests for VFS layer
* Small fixes found during testing
* Fix Close, Flush and Release behaviour for ReadFileHandle and WriteFileHandle
* Fix nil object bugs on File
2017-11-04 10:24:10 +00:00
Nick Craig-Wood
8184ec4b70
vfs: add EPERM to errors
2017-11-03 13:00:00 +00:00
Nick Craig-Wood
190367d917
vfs: factor duplicated Open code into vfs from mount/cmount
2017-11-03 13:00:00 +00:00
Nick Craig-Wood
a5dc62f6c1
vfs: Make file handles compatible with OS
...
* Implement directory handles
* Unify OpenFile
* Add all the methods to match *os.File
* Add StatParent and Rename methods to VFS
2017-11-03 13:00:00 +00:00
Nick Craig-Wood
3e0c91ba4b
vfs: Move DefaultOpt to vfs and make some methods private
2017-11-03 13:00:00 +00:00
Nick Craig-Wood
7e065440fb
vfs: rename Lookup to Stat to be more in keeping with os
2017-11-03 12:59:59 +00:00
Nick Craig-Wood
e8883e9fdb
vfs: factor flags into vfsflags and remove global variables
2017-11-03 12:59:59 +00:00
Nick Craig-Wood
1a8f824bad
vfs: use os package errors where possible
2017-11-03 12:59:59 +00:00
Nick Craig-Wood
c1aaff220d
Factor new vfs module out of cmd/mountlib
...
This is an OS style file system abstraction with directory caching
used in mount, cmount, serve webdav and serve http.
2017-11-03 12:59:59 +00:00