You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by st...@apache.org on 2011/10/27 23:48:01 UTC
svn commit: r1190049 - in /hbase/branches/0.92: CHANGES.txt
src/test/java/org/apache/hadoop/hbase/master/TestDistributedLogSplitting.java
Author: stack
Date: Thu Oct 27 21:48:01 2011
New Revision: 1190049
URL: http://svn.apache.org/viewvc?rev=1190049&view=rev
Log:
HBASE-4685 TestDistributedLogSplitting.testOrphanLogCreation failing because of ArithmeticException: / by zero.
Modified:
hbase/branches/0.92/CHANGES.txt
hbase/branches/0.92/src/test/java/org/apache/hadoop/hbase/master/TestDistributedLogSplitting.java
Modified: hbase/branches/0.92/CHANGES.txt
URL: http://svn.apache.org/viewvc/hbase/branches/0.92/CHANGES.txt?rev=1190049&r1=1190048&r2=1190049&view=diff
==============================================================================
--- hbase/branches/0.92/CHANGES.txt (original)
+++ hbase/branches/0.92/CHANGES.txt Thu Oct 27 21:48:01 2011
@@ -379,6 +379,8 @@ Release 0.92.0 - Unreleased
HBASE-4673 NPE in HFileReaderV2.close during major compaction when
hfile.block.cache.size is set to 0 (Lars H)
HBASE-4388 Second start after migration from 90 to trunk crashes
+ HBASE-4685 TestDistributedLogSplitting.testOrphanLogCreation failing because
+ of ArithmeticException: / by zero.
TESTS
HBASE-4492 TestRollingRestart fails intermittently
Modified: hbase/branches/0.92/src/test/java/org/apache/hadoop/hbase/master/TestDistributedLogSplitting.java
URL: http://svn.apache.org/viewvc/hbase/branches/0.92/src/test/java/org/apache/hadoop/hbase/master/TestDistributedLogSplitting.java?rev=1190049&r1=1190048&r2=1190049&view=diff
==============================================================================
--- hbase/branches/0.92/src/test/java/org/apache/hadoop/hbase/master/TestDistributedLogSplitting.java (original)
+++ hbase/branches/0.92/src/test/java/org/apache/hadoop/hbase/master/TestDistributedLogSplitting.java Thu Oct 27 21:48:01 2011
@@ -360,20 +360,22 @@ public class TestDistributedLogSplitting
int n = hris.size();
int[] counts = new int[n];
int j = 0;
- for (int i = 0; i < num_edits; i += 1) {
- WALEdit e = new WALEdit();
- byte [] row = Bytes.toBytes("r" + Integer.toString(i));
- byte [] family = Bytes.toBytes("f");
- byte [] qualifier = Bytes.toBytes("c" + Integer.toString(i));
- e.add(new KeyValue(row, family, qualifier,
- System.currentTimeMillis(), value));
- // LOG.info("Region " + i + ": " + e);
- j++;
- log.append(hris.get(j % n), table, e, System.currentTimeMillis(), htd);
- counts[j % n] += 1;
- // if ((i % 8096) == 0) {
+ if (n > 0) {
+ for (int i = 0; i < num_edits; i += 1) {
+ WALEdit e = new WALEdit();
+ byte [] row = Bytes.toBytes("r" + Integer.toString(i));
+ byte [] family = Bytes.toBytes("f");
+ byte [] qualifier = Bytes.toBytes("c" + Integer.toString(i));
+ e.add(new KeyValue(row, family, qualifier,
+ System.currentTimeMillis(), value));
+ // LOG.info("Region " + i + ": " + e);
+ j++;
+ log.append(hris.get(j % n), table, e, System.currentTimeMillis(), htd);
+ counts[j % n] += 1;
+ // if ((i % 8096) == 0) {
// log.sync();
- // }
+ // }
+ }
}
log.sync();
log.close();