You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by jx...@apache.org on 2012/08/16 23:05:39 UTC

svn commit: r1374061 - /hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestAdmin.java

Author: jxiang
Date: Thu Aug 16 21:05:38 2012
New Revision: 1374061

URL: http://svn.apache.org/viewvc?rev=1374061&view=rev
Log:
HBASE-6593 TestAdmin times out sometimes

Modified:
    hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestAdmin.java

Modified: hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestAdmin.java
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestAdmin.java?rev=1374061&r1=1374060&r2=1374061&view=diff
==============================================================================
--- hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestAdmin.java (original)
+++ hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestAdmin.java Thu Aug 16 21:05:38 2012
@@ -875,16 +875,19 @@ public class TestAdmin {
       numVersions, blockSize);
     try {
       int rowCount = 0;
+      byte[] q = new byte[0];
 
       // insert rows into column families. The number of rows that have values
       // in a specific column family is decided by rowCounts[familyIndex]
       for (int index = 0; index < familyNames.length; index++) {
+        ArrayList<Put> puts = new ArrayList<Put>(rowCounts[index]);
         for (int i = 0; i < rowCounts[index]; i++) {
           byte[] k = Bytes.toBytes(i);
           Put put = new Put(k);
-          put.add(familyNames[index], new byte[0], k);
-          table.put(put);
+          put.add(familyNames[index], q, k);
+          puts.add(put);
         }
+        table.put(puts);
 
         if ( rowCount < rowCounts[index] ) {
           rowCount = rowCounts[index];