Skip to content

Commit

Permalink
#47 Knock down a couple long tail tests and a resource abuser.
Browse files Browse the repository at this point in the history
  • Loading branch information
markrmiller committed Jul 10, 2020
1 parent a917b6c commit 2856b0a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ public void setUp() throws Exception {
assertU(commit());
}

@Nightly
public void testStats() throws Exception {
for (String f : new String[] {
"stats_i","stats_l","stats_f","stats_d",
Expand Down Expand Up @@ -1328,7 +1329,8 @@ public static void create(Stat stat, String input,
ALL.put(stat, new ExpectedStat(stat, input, perShardXpaths, finalXpaths));
}
}


@Nightly
public void testIndividualStatLocalParams() throws Exception {
final String kpre = ExpectedStat.KPRE;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1019,6 +1019,7 @@ public void testSortedSubFacetRefinementWhenParentOnlyReturnedByOneShardProcessE


@Test
@Nightly
public void testBasicRefinement() throws Exception {
ModifiableSolrParams p;
p = params("cat_s", "cat_s", "cat_i", "cat_i", "date","cat_dt", "xy_s", "xy_s", "num_d", "num_d", "qw_s", "qw_s", "er_s", "er_s");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public class BlockCacheTest extends SolrTestCase {

@Test
public void testBlockCache() {
int blocksInTest = 2000000;
int blocksInTest = TEST_NIGHTLY ? 2000000 : 20000;
int blockSize = 1024;

int slabSize = blockSize * 4096;
Expand All @@ -57,7 +57,7 @@ public void testBlockCache() {
AtomicLong missesInCache = new AtomicLong();
long storeTime = 0;
long fetchTime = 0;
int passes = 10000;
int passes = TEST_NIGHTLY ? 10000 : 10;

BlockCacheKey blockCacheKey = new BlockCacheKey();

Expand Down Expand Up @@ -112,7 +112,7 @@ private static byte getByte(long pos) {
public void testBlockCacheConcurrent() throws Exception {
Random rnd = random();

final int blocksInTest = 400; // pick something bigger than 256, since that would lead to a slab size of 64 blocks and the bitset locks would consist of a single word.
final int blocksInTest = TEST_NIGHTLY ? 400 : 40; // pick something bigger than 256, since that would lead to a slab size of 64 blocks and the bitset locks would consist of a single word.
final int blockSize = 64;
final int slabSize = blocksInTest * blockSize / 4;
final long totalMemory = 2 * slabSize; // 2 slabs of memory, so only half of what is needed for all blocks
Expand All @@ -124,7 +124,7 @@ public void testBlockCacheConcurrent() throws Exception {
final long totalMemory = 2 * slabSize; // 2 slabs of memory, so only half of what is needed for all blocks
***/

final int nThreads = 64;
final int nThreads = TEST_NIGHTLY ? Runtime.getRuntime().availableProcessors() : 5;
final int nReads = 1000000;
final int readsPerThread = nReads / nThreads;
final int readLastBlockOdds = 10; // odds (1 in N) of the next block operation being on the same block as the previous operation... helps flush concurrency issues
Expand Down

0 comments on commit 2856b0a

Please sign in to comment.