git-annex/Remote/Helper
Joey Hess 69f8e6c7c0
ImportableContentsChunkable
This improves the borg special remote memory usage, by
letting it only load one archive's worth of filenames into memory at a
time, and building up a larger tree out of the chunks.

When a borg repository has many archives, git-annex could easily OOM
before. Now, it will use only memory proportional to the number of
annexed keys in an archive.

Minor implementation wart: Each new chunk re-opens the content
identifier database, and also a new vector clock is used for each chunk.
This is a minor innefficiency only; the use of continuations makes
it hard to avoid, although putting the database handle into a Reader
monad would be one way to fix it.

It may later be possible to extend the ImportableContentsChunkable
interface to remotes that are not third-party populated. However, that
would perhaps need an interface that does not use continuations.

The ImportableContentsChunkable interface currently does not allow
populating the top of the tree with anything other than subtrees. It
would be easy to extend it to allow putting files in that tree, but borg
doesn't need that so I left it out for now.

Sponsored-by: Noam Kremen on Patreon
2021-10-08 13:15:22 -04:00
..
Chunked incremental checksum on download from ssh or p2p 2021-02-09 17:03:27 -04:00
AWS.hs include credPairRemoteFields in RemoteConfigParsers 2020-01-15 10:57:45 -04:00
Chunked.hs distinguish between incremental verification failing and not being done 2021-08-18 14:38:02 -04:00
Encryptable.hs Avoid more than 1 gpg password prompt at the same time 2021-04-27 16:36:44 -04:00
ExportImport.hs plumb VerifyConfig into retrieveKeyFile 2021-08-17 12:43:13 -04:00
Git.hs convert TopFilePath to use RawFilePath 2019-12-09 15:07:21 -04:00
Hooks.hs plumb VerifyConfig into retrieveKeyFile 2021-08-17 12:43:13 -04:00
Http.hs refactor 2021-08-18 13:19:02 -04:00
Messages.hs remove "checking remotename" message 2021-04-27 13:05:27 -04:00
P2P.hs simplify annex.bwlimit handling 2021-09-22 10:52:01 -04:00
ReadOnly.hs convert renameExport to throw exception 2020-05-15 15:08:09 -04:00
Special.hs simplify annex.bwlimit handling 2021-09-22 10:52:01 -04:00
Ssh.hs remove "checking remotename" message 2021-04-27 13:05:27 -04:00
ThirdPartyPopulated.hs ImportableContentsChunkable 2021-10-08 13:15:22 -04:00