You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by GitBox <gi...@apache.org> on 2021/05/10 14:25:47 UTC

[GitHub] [hbase] busbey commented on a change in pull request #3242: HBASE-25867 Extra doc around ITBLL

busbey commented on a change in pull request #3242:
URL: https://github.com/apache/hbase/pull/3242#discussion_r629402331



##########
File path: hbase-it/src/test/java/org/apache/hadoop/hbase/IntegrationTestingUtility.java
##########
@@ -58,8 +58,9 @@ public IntegrationTestingUtility(Configuration conf) {
    */
   public static final String IS_DISTRIBUTED_CLUSTER = "hbase.test.cluster.distributed";
 
-  /** Config for pluggable hbase cluster manager */
-  private static final String HBASE_CLUSTER_MANAGER_CLASS = "hbase.it.clustermanager.class";
+  /** Config for pluggable hbase cluster manager. Pass fully-qualified class name as property
+   * value. Drop the '.class' suffix.*/
+  public static final String HBASE_CLUSTER_MANAGER_CLASS = "hbase.it.clustermanager.class";

Review comment:
       Are we using this constant somewhere that needs it to be public instead of private? I'm not seeing it.

##########
File path: hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
##########
@@ -1661,17 +1661,19 @@ public boolean balance(boolean force) throws IOException {
         // if hbase:meta region is in transition, result of assignment cannot be recorded
         // ignore the force flag in that case
         boolean metaInTransition = assignmentManager.isMetaRegionInTransition();
-        String prefix = force && !metaInTransition ? "R" : "Not r";
         List<RegionStateNode> toPrint = regionsInTransition;
         int max = 5;
         boolean truncated = false;
         if (regionsInTransition.size() > max) {
           toPrint = regionsInTransition.subList(0, max);
           truncated = true;
         }
-        LOG.info(prefix + " not running balancer because " + regionsInTransition.size() +
-          " region(s) in transition: " + toPrint + (truncated? "(truncated list)": ""));
-        if (!force || metaInTransition) return false;
+        if (!force || metaInTransition) {
+          LOG.info("Not running balancer (force=" + force + ", metaRIT=" + metaInTransition +
+            ") because " + regionsInTransition.size() + " region(s) in transition: " + toPrint +
+            (truncated? "(truncated list)": ""));
+          return false;
+        }

Review comment:
       just want to confirm we have some other message that logs when the balancer runs?
   
   The message here for the running case was not great, but it was still text I could grep a log for.

##########
File path: hbase-it/src/test/java/org/apache/hadoop/hbase/chaos/util/ChaosMonkeyRunner.java
##########
@@ -168,19 +169,33 @@ public TableName getTablename() {
   }
 
   /*
-   * If caller wants to add config parameters contained in a file, the path of conf file
-   * can be passed as the first two arguments like this:
-   *   -c <path-to-conf>
+   * If caller wants to add config parameters from a file, the path to the conf file
+   * can be passed like this: -c <path-to-conf>. The file is presumed to have the Configuration
+   * file xml format and is added as a new Resource to the current Configuration.
+   * Use this mechanism to set Configuration such as what ClusterManager to use, etc.
+   * Here is an example file you might references that sets an alternate ClusterManager:
+   * {code}
+   * <?xml version="1.0" encoding="UTF-8"?>
+   * <configuration>
+   *   <property>
+   *     <name>hbase.it.clustermanager.class</name>
+   *     <value>org.apache.hadoop.hbase.K8sClusterManager</value>
+   *   </property>

Review comment:
       use an example classname that exists in the project please or make it flagrantly a user provided example, e.g. `com.example.my.hbase.CustomClusterManager`




-- 
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:
users@infra.apache.org