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 2020/07/07 06:20:24 UTC

[GitHub] [hbase] nyl3532016 commented on a change in pull request #2018: HBASE-24659 Calculate FIXED_OVERHEAD automatically

nyl3532016 commented on a change in pull request #2018:
URL: https://github.com/apache/hbase/pull/2018#discussion_r450634634



##########
File path: hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java
##########
@@ -8405,12 +8405,7 @@ private static long getLongValue(final Cell cell) throws DoNotRetryIOException {
     return cells;
   }
 
-  public static final long FIXED_OVERHEAD = ClassSize.align(
-      ClassSize.OBJECT +
-      56 * ClassSize.REFERENCE +
-      3 * Bytes.SIZEOF_INT +
-      14 * Bytes.SIZEOF_LONG +
-      3 * Bytes.SIZEOF_BOOLEAN);
+  public static final long FIXED_OVERHEAD = ClassSize.estimateBase(HRegion.class, false);

Review comment:
       I think ClassSize.estimateBase only calculate shallow size 
   




----------------------------------------------------------------
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