You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by ap...@apache.org on 2021/07/27 00:10:44 UTC

[hbase] branch branch-2.4 updated: HBASE-26123 Restore fields dropped by HBASE-25986 to public interfaces (#3527)

This is an automated email from the ASF dual-hosted git repository.

apurtell pushed a commit to branch branch-2.4
in repository https://gitbox.apache.org/repos/asf/hbase.git


The following commit(s) were added to refs/heads/branch-2.4 by this push:
     new 17ebbf0  HBASE-26123 Restore fields dropped by HBASE-25986 to public interfaces (#3527)
17ebbf0 is described below

commit 17ebbf0ecd6299683acd1ac04ecf3d60b5bc43d2
Author: Andrew Purtell <ap...@apache.org>
AuthorDate: Mon Jul 26 17:10:17 2021 -0700

    HBASE-26123 Restore fields dropped by HBASE-25986 to public interfaces (#3527)
    
    Self-approving trivial change.
    
    Signed-off-by: Andrew Purtell <ap...@apache.org>
---
 .../src/main/java/org/apache/hadoop/hbase/HTableDescriptor.java   | 1 +
 .../org/apache/hadoop/hbase/client/TableDescriptorBuilder.java    | 8 +++++++-
 2 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/HTableDescriptor.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/HTableDescriptor.java
index ff3e83e..c537c50 100644
--- a/hbase-client/src/main/java/org/apache/hadoop/hbase/HTableDescriptor.java
+++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/HTableDescriptor.java
@@ -57,6 +57,7 @@ public class HTableDescriptor implements TableDescriptor, Comparable<HTableDescr
   public static final Bytes OWNER_KEY = TableDescriptorBuilder.OWNER_KEY;
   public static final String READONLY = TableDescriptorBuilder.READONLY;
   public static final String COMPACTION_ENABLED = TableDescriptorBuilder.COMPACTION_ENABLED;
+  public static final boolean DEFAULT_NORMALIZATION_ENABLED = TableDescriptorBuilder.DEFAULT_NORMALIZATION_ENABLED;
   public static final String SPLIT_ENABLED = TableDescriptorBuilder.SPLIT_ENABLED;
   public static final String MERGE_ENABLED = TableDescriptorBuilder.MERGE_ENABLED;
   public static final String MEMSTORE_FLUSHSIZE = TableDescriptorBuilder.MEMSTORE_FLUSHSIZE;
diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/TableDescriptorBuilder.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/TableDescriptorBuilder.java
index 91dd6a3..1f33b06 100644
--- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/TableDescriptorBuilder.java
+++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/TableDescriptorBuilder.java
@@ -111,6 +111,12 @@ public class TableDescriptorBuilder {
   private static final Bytes MERGE_ENABLED_KEY = new Bytes(Bytes.toBytes(MERGE_ENABLED));
 
   /**
+   * Constant that denotes whether the table is normalized by default.
+   */
+  @InterfaceAudience.Private
+  public static final boolean DEFAULT_NORMALIZATION_ENABLED = false;
+
+  /**
    * Used by HBase Shell interface to access this metadata
    * attribute which represents the maximum size of the memstore after which its
    * contents are flushed onto the disk.
@@ -872,7 +878,7 @@ public class TableDescriptorBuilder {
      **/
     @Override
     public boolean isNormalizationEnabled() {
-      return getOrDefault(NORMALIZATION_ENABLED_KEY, Boolean::valueOf, false);
+      return getOrDefault(NORMALIZATION_ENABLED_KEY, Boolean::valueOf, DEFAULT_NORMALIZATION_ENABLED);
     }
 
     /**