avoid borg list of archives that have been listed before
authorJoey Hess <joeyh@joeyh.name>
Tue, 22 Dec 2020 18:06:40 +0000 (14:06 -0400)
committerJoey Hess <joeyh@joeyh.name>
Tue, 22 Dec 2020 18:06:40 +0000 (14:06 -0400)
commit5d8e4a7c741de0935f2bc5f0f8d06d9c9f31383d
tree5434f7067ae1e07ae8aad1c21b90c35285eead14
parent06ef1b7d68ee2b149e663f2362e5685303d0bd3a
avoid borg list of archives that have been listed before

This makes sync a lot faster in the common case where there's no new
backup.

There's still room for it to be faster. Currently the old imported tree
has to be traversed, to generate the ImportableContents. Which then
gets turned around to generate the new imported tree, which is
identical. So, it would be possible to just return a "no new imports",
or an ImportableContents that has a way to graft in a tree. The latter
is probably too far to go to optimise this, unless other things need it.
The former might be worth it, but it's already pretty fast, since git
ls-tree is pretty fast.
Git/LsTree.hs
Git/Types.hs
Logs/Export.hs
Remote/Borg.hs