@InterfaceAudience.Private public class RSGroupAdminServer extends Object implements RSGroupAdmin
| 构造器和说明 |
|---|
RSGroupAdminServer(MasterServices master,
RSGroupInfoManager RSGroupInfoManager) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
addRSGroup(String name)
Creates a new RegionServer group with the given name.
|
boolean |
balanceRSGroup(String groupName)
Balance regions in the given RegionServer group.
|
void |
cleanupRSGroupForTable(TableName tableName) |
void |
close() |
RSGroupInfo |
getRSGroupInfo(String groupName)
Gets
RSGroupInfo for given group name. |
RSGroupInfoManager |
getRSGroupInfoManager() |
RSGroupInfo |
getRSGroupInfoOfTable(TableName tableName)
Gets
RSGroupInfo for the given table's group. |
RSGroupInfo |
getRSGroupOfServer(Address server)
Retrieve the RSGroupInfo a server is affiliated to
|
List<RSGroupInfo> |
listRSGroups()
Lists current set of RegionServer groups.
|
void |
moveServers(Set<Address> servers,
String targetGroupName)
Move given set of servers to the specified target RegionServer group.
|
void |
moveServersAndTables(Set<Address> servers,
Set<TableName> tables,
String targetGroup)
Move given set of servers and tables to the specified target RegionServer group.
|
void |
moveTables(Set<TableName> tables,
String targetGroup)
Move given set of tables to the specified target RegionServer group.
|
void |
prepareRSGroupForTable(HTableDescriptor desc) |
void |
removeRSGroup(String name)
Removes RegionServer group associated with the given name.
|
void |
removeServers(Set<Address> servers)
Remove decommissioned servers from rsgroup.
1.
|
public RSGroupAdminServer(MasterServices master, RSGroupInfoManager RSGroupInfoManager) throws IOException
IOExceptionpublic RSGroupInfo getRSGroupInfo(String groupName) throws IOException
RSGroupAdminRSGroupInfo for given group name.getRSGroupInfo 在接口中 RSGroupAdminIOExceptionpublic RSGroupInfo getRSGroupInfoOfTable(TableName tableName) throws IOException
RSGroupAdminRSGroupInfo for the given table's group.getRSGroupInfoOfTable 在接口中 RSGroupAdminIOExceptionpublic void moveServers(Set<Address> servers, String targetGroupName) throws IOException
RSGroupAdminmoveServers 在接口中 RSGroupAdminIOExceptionpublic void moveTables(Set<TableName> tables, String targetGroup) throws IOException
RSGroupAdminmoveTables 在接口中 RSGroupAdminIOExceptionpublic void addRSGroup(String name) throws IOException
RSGroupAdminaddRSGroup 在接口中 RSGroupAdminIOExceptionpublic void removeRSGroup(String name) throws IOException
RSGroupAdminremoveRSGroup 在接口中 RSGroupAdminIOExceptionpublic boolean balanceRSGroup(String groupName) throws IOException
RSGroupAdminbalanceRSGroup 在接口中 RSGroupAdminIOExceptionpublic List<RSGroupInfo> listRSGroups() throws IOException
RSGroupAdminlistRSGroups 在接口中 RSGroupAdminIOExceptionpublic RSGroupInfo getRSGroupOfServer(Address server) throws IOException
RSGroupAdmingetRSGroupOfServer 在接口中 RSGroupAdminserver - HostPort to get RSGroupInfo forIOException@InterfaceAudience.Private public RSGroupInfoManager getRSGroupInfoManager() throws IOException
IOExceptionpublic void removeServers(Set<Address> servers) throws IOException
RSGroupAdminremoveServers 在接口中 RSGroupAdminservers - set of servers to removeIOExceptionpublic void prepareRSGroupForTable(HTableDescriptor desc) throws IOException
IOExceptionpublic void cleanupRSGroupForTable(TableName tableName) throws IOException
IOExceptionpublic void moveServersAndTables(Set<Address> servers, Set<TableName> tables, String targetGroup) throws IOException
RSGroupAdminmoveServersAndTables 在接口中 RSGroupAdminservers - set of servers to movetables - set of tables to movetargetGroup - the target group nameIOExceptionpublic void close()
throws IOException
close 在接口中 Closeableclose 在接口中 AutoCloseableIOExceptionCopyright © 2007–2021 The Apache Software Foundation. All rights reserved.