public class KitRaft extends Object
| 构造器和说明 |
|---|
KitRaft() |
KitRaft(GroupConfig groupConfig,
NodeConfig nodeConfig,
DB db) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
addNode(String nodeConf) |
List<String> |
getAliveNodes() |
DB |
getDB() |
DBStateMachine |
getFsm() |
String |
getLeader() |
String |
getLeaderIP() |
protected com.alipay.sofa.jraft.Node |
getNode() |
List<String> |
getNodes() |
boolean |
isLeader() |
protected com.alipay.sofa.jraft.RaftGroupService |
RaftGroupService() |
void |
removeNode(String nodeConf) |
void |
transferLeader(String nodeConf) |
public KitRaft()
public KitRaft(GroupConfig groupConfig, NodeConfig nodeConfig, DB db) throws IOException
IOExceptionpublic DB getDB()
public void addNode(String nodeConf)
public void removeNode(String nodeConf)
public void transferLeader(String nodeConf)
public String getLeader()
public String getLeaderIP()
public boolean isLeader()
public DBStateMachine getFsm()
protected com.alipay.sofa.jraft.Node getNode()
protected com.alipay.sofa.jraft.RaftGroupService RaftGroupService()
Copyright © 2020. All rights reserved.