public class LogAppender extends Object
| Modifier and Type | Class and Description |
|---|---|
protected class |
LogAppender.SnapshotRequestIter |
| Modifier and Type | Field and Description |
|---|---|
static org.slf4j.Logger |
LOG |
| Constructor and Description |
|---|
LogAppender(RaftServerImpl server,
LeaderState leaderState,
FollowerInfo f) |
public LogAppender(RaftServerImpl server, LeaderState leaderState, FollowerInfo f)
public RaftServerImpl getServer()
public RaftLog getRaftLog()
public long getHalfMinTimeoutMs()
public boolean isAppenderRunning()
public void stopAppender()
public FollowerInfo getFollower()
protected RaftPeerId getFollowerId()
protected org.apache.ratis.proto.RaftProtos.AppendEntriesRequestProto createRequest(long callId) throws RaftLogIOException
RaftLogIOExceptionprotected void updateCommitIndex(long commitIndex)
protected org.apache.ratis.proto.RaftProtos.InstallSnapshotRequestProto createInstallSnapshotNotificationRequest(TermIndex firstLogStartTermIndex)
protected SnapshotInfo shouldInstallSnapshot()
protected void runAppenderImpl()
throws InterruptedException,
IOException
InterruptedExceptionIOExceptionprotected void submitEventOnSuccessAppend()
protected void checkSlowness()
public void notifyAppend()
protected boolean shouldSendRequest()
protected boolean shouldHeartbeat()
protected long getHeartbeatRemainingTime()
protected boolean checkResponseTerm(long responseTerm)
Copyright © 2017–2020 The Apache Software Foundation. All rights reserved.