|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
@InterfaceAudience.Private public interface ReplicationQueues
This provides an interface for maintaining a region server's replication queues. These queues keep track of the HLogs that still need to be replicated to remote clusters.
| Method Summary | |
|---|---|
void |
addLog(String queueId,
String filename)
Add a new HLog file to the given queue. |
SortedMap<String,SortedSet<String>> |
claimQueues(String regionserver)
Take ownership for the set of queues belonging to a dead region server. |
List<String> |
getAllQueues()
Get a list of all queues for this region server. |
List<String> |
getListOfReplicators()
Get a list of all region servers that have outstanding replication queues. |
long |
getLogPosition(String queueId,
String filename)
Get the current position for a specific HLog in a given queue. |
List<String> |
getLogsInQueue(String queueId)
Get a list of all HLogs in the given queue. |
void |
init(String serverName)
Initialize the region server replication queue interface. |
void |
removeAllQueues()
Remove all replication queues for this region server. |
void |
removeLog(String queueId,
String filename)
Remove an HLog file from the given queue. |
void |
removeQueue(String queueId)
Remove a replication queue. |
void |
setLogPosition(String queueId,
String filename,
long position)
Set the current position for a specific HLog in a given queue. |
| Method Detail |
|---|
void init(String serverName)
throws org.apache.zookeeper.KeeperException
serverName - The server name of the region server that owns the replication queues this
interface manages.
org.apache.zookeeper.KeeperExceptionvoid removeQueue(String queueId)
queueId - a String that identifies the queue.
void addLog(String queueId,
String filename)
throws org.apache.zookeeper.KeeperException
queueId - a String that identifies the queue.filename - name of the HLog
org.apache.zookeeper.KeeperException
void removeLog(String queueId,
String filename)
queueId - a String that identifies the queue.filename - name of the HLog
void setLogPosition(String queueId,
String filename,
long position)
queueId - a String that identifies the queuefilename - name of the HLogposition - the current position in the file
long getLogPosition(String queueId,
String filename)
throws org.apache.zookeeper.KeeperException
queueId - a String that identifies the queuefilename - name of the HLog
org.apache.zookeeper.KeeperExceptionvoid removeAllQueues()
List<String> getLogsInQueue(String queueId)
queueId - a String that identifies the queue
List<String> getAllQueues()
SortedMap<String,SortedSet<String>> claimQueues(String regionserver)
regionserver - the id of the dead region server
List<String> getListOfReplicators()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||