public final class SlotTable extends Object implements Serializable
| 限定符和类型 | 类和说明 |
|---|---|
static class |
SlotTable.SlotTableBuilder |
| 构造器和说明 |
|---|
SlotTable(long epoch,
Collection<Slot> slots) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
assertSlotLessThan(SlotTable slotTable) |
boolean |
equals(Object o) |
SlotTable |
filter(Set<Integer> slotIds) |
SlotTable |
filter(String ip) |
SlotTable |
filterLeaderInfo() |
Set<String> |
getDataServers() |
long |
getEpoch()
Getter method for property epoch.
|
int |
getFollowerNum(String dataServerIp) |
int |
getLeaderNum(String dataServerIp) |
Slot |
getSlot(int slotId) |
Set<Integer> |
getSlotIds() |
Map<Integer,Slot> |
getSlotMap() |
int |
getSlotNum() |
List<Slot> |
getSlots() |
int |
hashCode() |
Map<Integer,String> |
slotLeaders() |
String |
toString() |
List<DataNodeSlot> |
transfer(String targetDataNode,
boolean ignoreFollowers)
the slot table is too big for rpc
|
public static final SlotTable INIT
public SlotTable(long epoch,
Collection<Slot> slots)
public Slot getSlot(int slotId)
public long getEpoch()
public List<DataNodeSlot> transfer(String targetDataNode, boolean ignoreFollowers)
targetDataNode - targetDataNodeignoreFollowers - ignoreFollowerspublic SlotTable filterLeaderInfo()
public int getLeaderNum(String dataServerIp)
public int getSlotNum()
public int getFollowerNum(String dataServerIp)
public void assertSlotLessThan(SlotTable slotTable)
Copyright © 2023 The Ant Financial. All rights reserved.