Package org.eclipse.jgit.internal.ketch
Class LagCheck
- java.lang.Object
-
- org.eclipse.jgit.internal.ketch.LagCheck
-
- All Implemented Interfaces:
java.lang.AutoCloseable
class LagCheck extends java.lang.Object implements java.lang.AutoCloseableA helper to check if aKetchReplicais ahead or behind the leader.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static classLagCheck.RefGoneException
-
Field Summary
Fields Modifier and Type Field Description private ObjectIdremoteIdprivate KetchReplicareplicaprivate Repositoryrepoprivate RevWalkrw
-
Constructor Summary
Constructors Constructor Description LagCheck(KetchReplica replica, Repository repo)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) KetchReplica.Statecheck(ObjectId acceptId, ReceiveCommand acceptCmd)voidclose()(package private) ObjectIdgetRemoteId()private voidinitRevWalk()private RevCommitparseRemoteCommit(java.lang.String refName)
-
-
-
Field Detail
-
replica
private final KetchReplica replica
-
repo
private final Repository repo
-
rw
private RevWalk rw
-
remoteId
private ObjectId remoteId
-
-
Constructor Detail
-
LagCheck
LagCheck(KetchReplica replica, Repository repo)
-
-
Method Detail
-
initRevWalk
private void initRevWalk()
-
close
public void close()
- Specified by:
closein interfacejava.lang.AutoCloseable
-
getRemoteId
ObjectId getRemoteId()
-
check
KetchReplica.State check(ObjectId acceptId, ReceiveCommand acceptCmd)
-
parseRemoteCommit
private RevCommit parseRemoteCommit(java.lang.String refName) throws java.io.IOException, MissingObjectException, LagCheck.RefGoneException
- Throws:
java.io.IOExceptionMissingObjectExceptionLagCheck.RefGoneException
-
-