clone: do faster object check for partial clones
commitdfa33a298de2ab724d4812633bb009a90d1df790
authorJosh Steadmon <steadmon@google.com>
Fri, 19 Apr 2019 21:00:13 +0000 (19 14:00 -0700)
committerJunio C Hamano <gitster@pobox.com>
Sun, 21 Apr 2019 05:08:53 +0000 (21 14:08 +0900)
treef15ffe4ed29fe4acadffd36d8c49057ecec538ce
parent041f5ea1cf987a4068ef5f39ba0a09be85952064
clone: do faster object check for partial clones

For partial clones, doing a full connectivity check is wasteful; we skip
promisor objects (which, for a partial clone, is all known objects), and
enumerating them all to exclude them from the connectivity check can
take a significant amount of time on large repos.

At most, we want to make sure that we get the objects referred to by any
wanted refs. For partial clones, just check that these objects were
transferred.

Signed-off-by: Josh Steadmon <steadmon@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/clone.c
connected.c
connected.h