git-annex/Remote
Joey Hess f6cf2dec4c
disk free checking for unsized keys
Improve disk free space checking when transferring unsized keys to
local git remotes. Since the size of the object file is known, can
check that instead.

Getting unsized keys from local git remotes does not check the actual
object size. It would be harder to handle that direction because the size
check is run locally, before anything involving the remote is done. So it
doesn't know the size of the file on the remote.

Also, transferring unsized keys to other remotes, including ssh remotes and
p2p remotes don't do disk size checking for unsized keys. This would need a
change in protocol.

(It does seem like it would be possible to implement the same thing for
directory special remotes though.)

In some sense, it might be better to not ever do disk free checking for
unsized keys, than to do it only sometimes. A user might notice this
direction working and consider it a bug that the other direction does not.
On the other hand, disk reserve checking is not implemented for most
special remotes at all, and yet it is implemented for a few, which is also
inconsistent, but best effort. And so doing this best effort seems to make
some sense. Fundamentally, if the user wants the size to always be checked,
they should not use unsized keys.

Sponsored-by: Brock Spratlen on Patreon
2024-01-16 14:29:10 -04:00
..
Directory improve createDirectoryUnder to allow alternate top directories 2022-08-12 12:52:37 -04:00
External let Remote.availability return Unavilable 2023-08-16 14:31:31 -04:00
Helper disk free checking for unsized keys 2024-01-16 14:29:10 -04:00
List auto-init autoenable=yes 2020-05-27 12:40:35 -04:00
Rsync add newtypes for QuickCheck to avoid LANG=C issues 2020-11-09 20:21:18 -04:00
WebDAV Apply codespell -w throughout 2023-03-17 15:14:58 -04:00
Adb.hs adb send to final filename not tmp file 2023-09-11 13:13:05 -04:00
BitTorrent.hs let Remote.availability return Unavilable 2023-08-16 14:31:31 -04:00
Borg.hs implement Unavilable for borg bup ddar directory rsync 2023-08-16 15:48:09 -04:00
Bup.hs implement Unavilable for borg bup ddar directory rsync 2023-08-16 15:48:09 -04:00
Ddar.hs implement Unavilable for borg bup ddar directory rsync 2023-08-16 15:48:09 -04:00
Directory.hs disk free checking for unsized keys 2024-01-16 14:29:10 -04:00
External.hs let Remote.availability return Unavilable 2023-08-16 14:31:31 -04:00
GCrypt.hs eliminate s2w8 and w82s 2023-10-26 13:12:57 -04:00
Git.hs disk free checking for unsized keys 2024-01-16 14:29:10 -04:00
GitLFS.hs Removed the vendored git-lfs and the GitLfs build flag 2023-08-28 13:12:31 -04:00
Glacier.hs let Remote.availability return Unavilable 2023-08-16 14:31:31 -04:00
Hook.hs let Remote.availability return Unavilable 2023-08-16 14:31:31 -04:00
HttpAlso.hs let Remote.availability return Unavilable 2023-08-16 14:31:31 -04:00
List.hs start borg special remote 2020-12-18 16:03:51 -04:00
P2P.hs let Remote.availability return Unavilable 2023-08-16 14:31:31 -04:00
Rsync.hs implement Unavilable for borg bup ddar directory rsync 2023-08-16 15:48:09 -04:00
S3.hs let Remote.availability return Unavilable 2023-08-16 14:31:31 -04:00
Tahoe.hs disk free checking for unsized keys 2024-01-16 14:29:10 -04:00
Web.hs let Remote.availability return Unavilable 2023-08-16 14:31:31 -04:00
WebDAV.hs let Remote.availability return Unavilable 2023-08-16 14:31:31 -04:00