Interface ReplicationOperations
-
- All Known Implementing Classes:
ReplicationOperationsImpl
public interface ReplicationOperationsSupports replication configuration- Since:
- 1.7.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddPeer(String name, String replicaType)Defines a cluster with the given name and the given name system.voiddrain(String tableName)Waits for a table to be fully replicated, given the state of files pending replication for the provided table at the point in time which this method is invoked.voiddrain(String tableName, Set<String> files)Given the provided set of files that are pending replication for a table, wait for those files to be fully replicated to all configured peers.Set<String>referencedFiles(String tableName)Gets all of the referenced files for a table from the metadata table.voidremovePeer(String name)Removes a cluster with the given name.
-
-
-
Method Detail
-
addPeer
void addPeer(String name, String replicaType) throws AccumuloException, AccumuloSecurityException, PeerExistsException
Defines a cluster with the given name and the given name system.- Parameters:
name- Unique name for the clusterreplicaType- Class name to use to replicate the data- Throws:
AccumuloExceptionAccumuloSecurityExceptionPeerExistsException
-
removePeer
void removePeer(String name) throws AccumuloException, AccumuloSecurityException, PeerNotFoundException
Removes a cluster with the given name.- Parameters:
name- Name of the cluster to remove- Throws:
AccumuloExceptionAccumuloSecurityExceptionPeerNotFoundException
-
drain
void drain(String tableName) throws AccumuloException, AccumuloSecurityException, TableNotFoundException
Waits for a table to be fully replicated, given the state of files pending replication for the provided table at the point in time which this method is invoked.- Parameters:
tableName- The table to wait for- Throws:
AccumuloExceptionAccumuloSecurityExceptionTableNotFoundException
-
drain
void drain(String tableName, Set<String> files) throws AccumuloException, AccumuloSecurityException, TableNotFoundException
Given the provided set of files that are pending replication for a table, wait for those files to be fully replicated to all configured peers. This allows for the accurate calculation when a table, at a given point in time, has been fully replicated.- Parameters:
tableName- The table to wait for- Throws:
AccumuloExceptionAccumuloSecurityExceptionTableNotFoundException
-
referencedFiles
Set<String> referencedFiles(String tableName) throws AccumuloException, AccumuloSecurityException, TableNotFoundException
Gets all of the referenced files for a table from the metadata table. The result of this method is intended to be directly supplied todrain(String, Set). This helps determine when all data from a given point in time has been fully replicated.This also allows callers to get the
Setof files for a table at some time, and later provide thatSettodrain(String,Set)to wait for all of those files to be replicated.
-
-