Apache9 commented on a change in pull request #1165: HBASE-22514 Move rsgroup 
feature into core of HBase
URL: https://github.com/apache/hbase/pull/1165#discussion_r378601572
 
 

 ##########
 File path: hbase-client/src/main/java/org/apache/hadoop/hbase/client/Admin.java
 ##########
 @@ -2262,4 +2265,104 @@ boolean snapshotCleanupSwitch(final boolean on, final 
boolean synchronous)
    */
   boolean isSnapshotCleanupEnabled() throws IOException;
 
+  /**
+   * Creates a new RegionServer group with the given name
+   * @param groupName the name of the group
+   * @throws IOException if a remote or network exception occurs
+   */
+  void addRSGroup(String groupName) throws IOException;
+
+  /**
+   * Get group info for the given group name
+   * @param groupName the group name
+   * @return group info
+   * @throws IOException if a remote or network exception occurs
+   */
+  RSGroupInfo getRSGroup(String groupName) throws IOException;
+
+  /**
+   * Get group info for the given hostPort
+   * @param hostPort HostPort to get RSGroupInfo for
+   * @throws IOException if a remote or network exception occurs
+   */
+  RSGroupInfo getRSGroup(Address hostPort) throws IOException;
+
+  /**
+   * Get group info for the given table
+   * @param tableName table name to get RSGroupInfo for
+   * @throws IOException if a remote or network exception occurs
+   */
+  RSGroupInfo getRSGroup(TableName tableName) throws IOException;
+
+  /**
+   * Lists current set of RegionServer groups
+   * @throws IOException if a remote or network exception occurs
+   */
+  List<RSGroupInfo> listRSGroups() throws IOException;
+
+  /**
+   * Get all tables in this RegionServer group.
+   * @param groupName the group name
+   * @throws IOException if a remote or network exception occurs
+   * @see #getConfiguredNamespacesAndTablesInRSGroup(String)
+   */
+  List<TableName> listTablesInRSGroup(String groupName) throws IOException;
+
+  /**
+   * Get the namespaces and tables which have this RegionServer group in 
descriptor.
+   * <p/>
+   * The difference between this method and {@link 
#listTablesInRSGroup(String)} is that, this
+   * method will not include the table which is actually in this RegionServr 
group but without the
+   * RegionServer group configuration in its {@link TableDescriptor}. For 
example, we have a group
+   * 'A', and we make namespace 'nsA' in this group, then all the tables under 
this namespace will
+   * in the group 'A', but this method will not return these tables but only 
the namespace 'nsA',
+   * while the {@link #listTablesInRSGroup(String)} will return all these 
tables.
+   * @param groupName the group name
+   * @throws IOException if a remote or network exception occurs
+   * @see #listTablesInRSGroup(String)
+   */
+  Pair<List<String>, List<TableName>> 
getConfiguredNamespacesAndTablesInRSGroup(String groupName)
 
 Review comment:
   But it is the 'configured' namespaces and tables. For example, you have 
namespace 'N' under rs group 'R', this method will only return namespace 'N', 
and will not return the tables under namespace 'N'...

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to