Author: tedyu
Date: Mon Apr  2 03:47:03 2012
New Revision: 1308232

URL: http://svn.apache.org/viewvc?rev=1308232&view=rev
Log:
HBASE-5436  Right-size the map when reading attributes (Benoit)

Modified:
    hbase/branches/0.92/CHANGES.txt
    
hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/client/OperationWithAttributes.java

Modified: hbase/branches/0.92/CHANGES.txt
URL: 
http://svn.apache.org/viewvc/hbase/branches/0.92/CHANGES.txt?rev=1308232&r1=1308231&r2=1308232&view=diff
==============================================================================
--- hbase/branches/0.92/CHANGES.txt (original)
+++ hbase/branches/0.92/CHANGES.txt Mon Apr  2 03:47:03 2012
@@ -30,6 +30,7 @@ Release 0.92.2 - Unreleased
    HBASE-5592  Make it easier to get a table from shell (Ben West)
    HBASE-5588  Deprecate/remove AssignmentManager#clearRegionFromTransition
    HBASE-5589  Add of the offline call to the Master Interface
+   HBASE-5436  Right-size the map when reading attributes (Benoit)
 
   NEW FEATURE
    HBASE-5128  [uber hbck] Online automated repair of table integrity and 
region consistency problems

Modified: 
hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/client/OperationWithAttributes.java
URL: 
http://svn.apache.org/viewvc/hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/client/OperationWithAttributes.java?rev=1308232&r1=1308231&r2=1308232&view=diff
==============================================================================
--- 
hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/client/OperationWithAttributes.java
 (original)
+++ 
hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/client/OperationWithAttributes.java
 Mon Apr  2 03:47:03 2012
@@ -96,7 +96,7 @@ public abstract class OperationWithAttri
   protected void readAttributes(final DataInput in) throws IOException {
     int numAttributes = in.readInt();
     if (numAttributes > 0) {
-      this.attributes = new HashMap<String, byte[]>();
+      this.attributes = new HashMap<String, byte[]>(numAttributes);
       for(int i=0; i<numAttributes; i++) {
         String name = WritableUtils.readString(in);
         byte[] value = Bytes.readByteArray(in);


Reply via email to