hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ser...@apache.org
Subject svn commit: r1470786 - in /hbase/branches/0.95: hbase-common/src/main/java/org/apache/hadoop/hbase/util/ hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/
Date Tue, 23 Apr 2013 02:46:27 GMT
Author: sershe
Date: Tue Apr 23 02:46:27 2013
New Revision: 1470786

URL: http://svn.apache.org/r1470786
Log:
HBASE-8384 heap size computation for HStore is fishy

Modified:
    hbase/branches/0.95/hbase-common/src/main/java/org/apache/hadoop/hbase/util/ClassSize.java
    hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HStore.java
    hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/ScanInfo.java

Modified: hbase/branches/0.95/hbase-common/src/main/java/org/apache/hadoop/hbase/util/ClassSize.java
URL: http://svn.apache.org/viewvc/hbase/branches/0.95/hbase-common/src/main/java/org/apache/hadoop/hbase/util/ClassSize.java?rev=1470786&r1=1470785&r2=1470786&view=diff
==============================================================================
--- hbase/branches/0.95/hbase-common/src/main/java/org/apache/hadoop/hbase/util/ClassSize.java
(original)
+++ hbase/branches/0.95/hbase-common/src/main/java/org/apache/hadoop/hbase/util/ClassSize.java
Tue Apr 23 02:46:27 2013
@@ -242,7 +242,6 @@ public class ClassSize {
           }
           if (debug) {
             if (LOG.isDebugEnabled()) {
-              // Write out region name as string and its encoded name.
               LOG.debug("" + index + " " + aField.getName() + " " + aField.getType());
             }
           }
@@ -269,7 +268,6 @@ public class ClassSize {
     long size = align(prealign_size);
     if(debug) {
       if (LOG.isDebugEnabled()) {
-        // Write out region name as string and its encoded name.
         LOG.debug("Primitives=" + coeff[0] + ", arrays=" + coeff[1] +
             ", references(includes " + nrOfRefsPerObj +
             " for object overhead)=" + coeff[2] + ", refSize " + REFERENCE +

Modified: hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HStore.java
URL: http://svn.apache.org/viewvc/hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HStore.java?rev=1470786&r1=1470785&r2=1470786&view=diff
==============================================================================
--- hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HStore.java
(original)
+++ hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HStore.java
Tue Apr 23 02:46:27 2013
@@ -1806,8 +1806,8 @@ public class HStore implements Store {
   }
 
   public static final long FIXED_OVERHEAD =
-      ClassSize.align((17 * ClassSize.REFERENCE) + (5 * Bytes.SIZEOF_LONG)
-              + (2 * Bytes.SIZEOF_INT) + Bytes.SIZEOF_BOOLEAN);
+      ClassSize.align(ClassSize.OBJECT + (16 * ClassSize.REFERENCE) + (4 * Bytes.SIZEOF_LONG)
+              + (2 * Bytes.SIZEOF_INT) + (2 * Bytes.SIZEOF_BOOLEAN));
 
   public static final long DEEP_OVERHEAD = ClassSize.align(FIXED_OVERHEAD
       + ClassSize.OBJECT + ClassSize.REENTRANT_LOCK

Modified: hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/ScanInfo.java
URL: http://svn.apache.org/viewvc/hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/ScanInfo.java?rev=1470786&r1=1470785&r2=1470786&view=diff
==============================================================================
--- hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/ScanInfo.java
(original)
+++ hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/ScanInfo.java
Tue Apr 23 02:46:27 2013
@@ -39,7 +39,7 @@ public class ScanInfo {
 
   public static final long FIXED_OVERHEAD = ClassSize.align(ClassSize.OBJECT
       + (2 * ClassSize.REFERENCE) + (2 * Bytes.SIZEOF_INT)
-      + Bytes.SIZEOF_LONG + Bytes.SIZEOF_BOOLEAN);
+      + (2 * Bytes.SIZEOF_LONG) + Bytes.SIZEOF_BOOLEAN);
 
   /**
    * @param family {@link HColumnDescriptor} describing the column family



Mime
View raw message