You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by mc...@apache.org on 2020/01/08 07:28:04 UTC
[cassandra] branch cassandra-2.2 updated: Reduce burn length by
reducing iteration count
This is an automated email from the ASF dual-hosted git repository.
mck pushed a commit to branch cassandra-2.2
in repository https://gitbox.apache.org/repos/asf/cassandra.git
The following commit(s) were added to refs/heads/cassandra-2.2 by this push:
new ca8469e Reduce burn length by reducing iteration count
ca8469e is described below
commit ca8469ecf56b460897e6bf92824f958dcfbb1083
Author: Mick Semb Wever <mc...@apache.org>
AuthorDate: Mon Jan 6 23:15:06 2020 +0100
Reduce burn length by reducing iteration count
patch by Mick Semb Wever; reviewed by Dinesh Joshi for CASSANDRA-15487
---
test/burn/org/apache/cassandra/utils/LongBTreeTest.java | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/test/burn/org/apache/cassandra/utils/LongBTreeTest.java b/test/burn/org/apache/cassandra/utils/LongBTreeTest.java
index 9641930..5b91a5e 100644
--- a/test/burn/org/apache/cassandra/utils/LongBTreeTest.java
+++ b/test/burn/org/apache/cassandra/utils/LongBTreeTest.java
@@ -59,6 +59,7 @@ import org.apache.cassandra.utils.btree.UpdateFunction;
// TODO : should probably lower fan-factor for tests to make them more intensive
public class LongBTreeTest
{
+ private static final int ITERATIONS = 10000;
private static final MetricRegistry metrics = new MetricRegistry();
private static final Timer BTREE_TIMER = metrics.timer(MetricRegistry.name(BTree.class, "BTREE"));
@@ -76,7 +77,7 @@ public class LongBTreeTest
public void testOversizedMiddleInsert()
{
TreeSet<Integer> canon = new TreeSet<>();
- for (int i = 0 ; i < 10000000 ; i++)
+ for (int i = 0 ; i < ITERATIONS ; i++)
canon.add(i);
Object[] btree = BTree.build(Arrays.asList(Integer.MIN_VALUE, Integer.MAX_VALUE), ICMP, true, null);
btree = BTree.update(btree, ICMP, canon, true);
@@ -89,31 +90,31 @@ public class LongBTreeTest
@Test
public void testIndividualInsertsSmallOverlappingRange() throws ExecutionException, InterruptedException
{
- testInsertions(10000000, 50, 1, 1, true);
+ testInsertions(ITERATIONS, 50, 1, 1, true);
}
@Test
public void testBatchesSmallOverlappingRange() throws ExecutionException, InterruptedException
{
- testInsertions(10000000, 50, 1, 5, true);
+ testInsertions(ITERATIONS, 50, 1, 5, true);
}
@Test
public void testIndividualInsertsMediumSparseRange() throws ExecutionException, InterruptedException
{
- testInsertions(10000000, 500, 10, 1, true);
+ testInsertions(ITERATIONS, 500, 10, 1, true);
}
@Test
public void testBatchesMediumSparseRange() throws ExecutionException, InterruptedException
{
- testInsertions(10000000, 500, 10, 10, true);
+ testInsertions(ITERATIONS, 500, 10, 10, true);
}
@Test
public void testLargeBatchesLargeRange() throws ExecutionException, InterruptedException
{
- testInsertions(100000000, 5000, 3, 100, true);
+ testInsertions(ITERATIONS * 10, 5000, 3, 100, true);
}
@Test
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org
For additional commands, e-mail: commits-help@cassandra.apache.org