diff options
author | Eric Wong <normalperson@yhbt.net> | 2016-04-26 00:17:28 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2016-05-12 00:56:00 +0300 |
commit | d9545c7f465ed103df44cd93caddfdd265757779 (patch) | |
tree | 6761dd88c70a108724c3db033689d328a8d1f5b4 /t/t9300-fast-import.sh | |
parent | 6a6636270fbaf74609cd3e1bd207dd2c420d640a (diff) |
fast-import: implement unpack limit
With many incremental imports, small packs become highly
inefficient due to the need to readdir scan and load many
indices to locate even a single object. Frequent repacking and
consolidation may be prohibitively expensive in terms of disk
I/O, especially in large repositories where the initial packs
were aggressively optimized and marked with .keep files.
In those cases, users may be better served with loose objects
and relying on "git gc --auto".
This changes the default behavior of fast-import for small
imports found in test cases, so adjustments to t9300 were
necessary.
Signed-off-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t9300-fast-import.sh')
-rwxr-xr-x | t/t9300-fast-import.sh | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/t/t9300-fast-import.sh b/t/t9300-fast-import.sh index 25bb60b281..e6a2b8a4d7 100755 --- a/t/t9300-fast-import.sh +++ b/t/t9300-fast-import.sh @@ -52,6 +52,7 @@ echo "$@"' ### test_expect_success 'empty stream succeeds' ' + git config fastimport.unpackLimit 0 && git fast-import </dev/null ' @@ -2675,6 +2676,7 @@ test_expect_success 'R: blob bigger than threshold' ' echo >>input && test_create_repo R && + git --git-dir=R/.git config fastimport.unpackLimit 0 && git --git-dir=R/.git fast-import --big-file-threshold=1 <input ' |