]> arthur.barton.de Git - bup.git/commit
vfs2: add trivial random eviction commit cache
authorRob Browning <rlb@defaultvalue.org>
Mon, 13 Nov 2017 04:44:03 +0000 (22:44 -0600)
committerRob Browning <rlb@defaultvalue.org>
Sun, 24 Dec 2017 19:24:42 +0000 (13:24 -0600)
commitdda87026d58e8386d593c0fada01f15f325ed8c3
tree9b288da33fe8f099a0c4a79aefd2f033eedf84bd
parentde9de86fa710e4635b43e5e071c93715982b4704
vfs2: add trivial random eviction commit cache

Porting rm and gc to vfs2 has put us at the point where we need at
least some caching so that we're not invoking git an endless number of
times when trying to "bup rm" 1000 saves (i.e. via test-prune-older if
nothing else).  Start with a very primitive, fixed-size commit cache
with random eviction.

It's not clear that the cache should always be enabled.  While it may
help commands like rm, prune-older, fuse, web, ftp, etc., it may often
just be extra baggage for for commands like restore, ls, cat-file, ...

Signed-off-by: Rob Browning <rlb@defaultvalue.org>
Tested-by: Rob Browning <rlb@defaultvalue.org>
lib/bup/t/tvfs.py
lib/bup/vfs2.py