Class FullConnectivityChecker
- java.lang.Object
-
- org.eclipse.jgit.internal.transport.connectivity.FullConnectivityChecker
-
- All Implemented Interfaces:
ConnectivityChecker
public final class FullConnectivityChecker extends java.lang.Object implements ConnectivityChecker
A connectivity checker that uses the entire reference database to perform reachability checks when checking the connectivity of objects. If info.isCheckObjects() is set it will also check that objects referenced by deltas are either provided or reachable as well.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.eclipse.jgit.transport.ConnectivityChecker
ConnectivityChecker.ConnectivityCheckInfo
-
-
Constructor Summary
Constructors Constructor Description FullConnectivityChecker()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private void
checkCommitTree(ConnectivityChecker.ConnectivityCheckInfo connectivityCheckInfo, ObjectWalk ow, ProgressMonitor pm)
void
checkConnectivity(ConnectivityChecker.ConnectivityCheckInfo connectivityCheckInfo, java.util.Set<ObjectId> haves, ProgressMonitor pm)
Checks connectivity of the commit graph after pack uploading.private void
checkObjects(ConnectivityChecker.ConnectivityCheckInfo connectivityCheckInfo, ObjectWalk ow, ProgressMonitor pm)
private boolean
markStartAndKnownNodes(ConnectivityChecker.ConnectivityCheckInfo connectivityCheckInfo, ObjectWalk ow, java.util.Set<ObjectId> haves, ProgressMonitor pm)
-
-
-
Method Detail
-
checkConnectivity
public void checkConnectivity(ConnectivityChecker.ConnectivityCheckInfo connectivityCheckInfo, java.util.Set<ObjectId> haves, ProgressMonitor pm) throws MissingObjectException, java.io.IOException
Description copied from interface:ConnectivityChecker
Checks connectivity of the commit graph after pack uploading.- Specified by:
checkConnectivity
in interfaceConnectivityChecker
- Parameters:
connectivityCheckInfo
- Input for the connectivity check.haves
- Set of references known for client.pm
- Monitor to publish progress to.- Throws:
java.io.IOException
- an error occurred during connectivity checking.MissingObjectException
-
markStartAndKnownNodes
private boolean markStartAndKnownNodes(ConnectivityChecker.ConnectivityCheckInfo connectivityCheckInfo, ObjectWalk ow, java.util.Set<ObjectId> haves, ProgressMonitor pm) throws java.io.IOException
- Parameters:
connectivityCheckInfo
- Source for connectivity check.ow
- Walk which can also check blobs.haves
- Set of references known for client.pm
- Monitor to publish progress to.- Returns:
- true if at least one new node was marked.
- Throws:
java.io.IOException
- an error occurred during connectivity checking.
-
checkCommitTree
private void checkCommitTree(ConnectivityChecker.ConnectivityCheckInfo connectivityCheckInfo, ObjectWalk ow, ProgressMonitor pm) throws java.io.IOException
- Parameters:
connectivityCheckInfo
- Source for connectivity check.ow
- Walk which can also check blobs.pm
- Monitor to publish progress to.- Throws:
java.io.IOException
- an error occurred during connectivity checking.
-
checkObjects
private void checkObjects(ConnectivityChecker.ConnectivityCheckInfo connectivityCheckInfo, ObjectWalk ow, ProgressMonitor pm) throws java.io.IOException
- Parameters:
connectivityCheckInfo
- Source for connectivity check.ow
- Walk which can also check blobs.pm
- Monitor to publish progress to.- Throws:
java.io.IOException
- an error occurred during connectivity checking.
-
-