jgit/org.eclipse.jgit
Luca Milanesio 21e902dd7f Shortcut during git fetch for avoiding looping through all local refs
The FetchProcess needs to verify that all the refs received point
to objects that are reachable from the local refs, which could be
very expensive but is needed to avoid missing objects exceptions
because of broken chains.

When the local repository has a lot of refs (e.g. millions) and the
client is fetching a non-commit object (e.g. refs/sequences/changes in
Gerrit) the reachability check on all local refs can be very expensive
compared to the time to fetch the remote ref.

Example for a 2M refs repository:
- fetching a single non-commit object: 50ms
- checking the reachability of local refs: 30s

A ref pointing to a non-commit object doesn't have any parent or
successor objects, hence would never need to have a reachability check
done. Skipping the askForIsComplete() altogether would save the 30s
time spent in an unnecessary phase.

Signed-off-by: Luca Milanesio <luca.milanesio@gmail.com>
Change-Id: I09ac66ded45cede199ba30f9e71cc1055f00941b
2023-02-01 00:07:45 +01:00
..
.settings Silence API warnings introduced by I466dcde6 2023-01-31 23:45:07 +01:00
META-INF Add missing package import javax.management to org.eclipse.jgit 2022-06-17 13:49:59 +02:00
findBugs [spotbugs] Silence NP_BOOLEAN_RETURN_NULL in IgnoreNode#checkIgnored 2020-12-22 10:52:59 +01:00
resources/org/eclipse/jgit AmazonS3: Add support for AWS API signature version 4 2022-06-13 09:44:23 +02:00
src/org/eclipse/jgit Shortcut during git fetch for avoiding looping through all local refs 2023-02-01 00:07:45 +01:00
.classpath
.fbprefs
.gitignore
.project
BUILD Fix stamping to produce stable file timestamps 2020-12-14 15:45:29 +01:00
about.html
build.properties
plugin.properties Fix bundle localization of Apache SSH bundle 2019-06-21 17:54:06 +02:00
pom.xml Prepare 5.13.2-SNAPSHOT builds 2022-06-14 00:41:18 +02:00