Skip to content

Commit

Permalink
remove unused configs, fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
clintropolis committed Aug 18, 2023
1 parent c1f4664 commit 7e5ed4d
Show file tree
Hide file tree
Showing 10 changed files with 0 additions and 55 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,6 @@ public class GroupByTypeInterfaceBenchmark
@Param({"100000"})
private int rowsPerSegment;

@Param({"v2"})
private String defaultStrategy;

@Param({"all"})
private String queryGranularity;

Expand Down Expand Up @@ -357,8 +354,6 @@ public HumanReadableBytes getMaxOnDiskStorage()
}
};
config.setSingleThreaded(false);
config.setMaxIntermediateRows(Integer.MAX_VALUE);
config.setMaxResults(Integer.MAX_VALUE);

DruidProcessingConfig druidProcessingConfig = new DruidProcessingConfig()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -469,8 +469,6 @@ public HumanReadableBytes getMaxOnDiskStorage()
}
};
config.setSingleThreaded(false);
config.setMaxIntermediateRows(Integer.MAX_VALUE);
config.setMaxResults(Integer.MAX_VALUE);

DruidProcessingConfig druidProcessingConfig = new DruidProcessingConfig()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ public class DistinctCountGroupByQueryTest extends InitializedNullHandlingTest
public void setup()
{
final GroupByQueryConfig config = new GroupByQueryConfig();
config.setMaxIntermediateRows(10000);
this.resourceCloser = Closer.create();
this.factory = GroupByQueryRunnerTest.makeQueryRunnerFactory(
config,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,6 @@ public class GroupByQueryConfig
@JsonProperty
private boolean singleThreaded = false;

@JsonProperty
private int maxIntermediateRows = 50000;

@JsonProperty
private int maxResults = 500000;

@JsonProperty
// Not documented, only used for tests to force spilling
private int bufferGrouperMaxSize = Integer.MAX_VALUE;
Expand Down Expand Up @@ -142,26 +136,6 @@ public void setSingleThreaded(boolean singleThreaded)
this.singleThreaded = singleThreaded;
}

public int getMaxIntermediateRows()
{
return maxIntermediateRows;
}

public void setMaxIntermediateRows(int maxIntermediateRows)
{
this.maxIntermediateRows = maxIntermediateRows;
}

public int getMaxResults()
{
return maxResults;
}

public void setMaxResults(int maxResults)
{
this.maxResults = maxResults;
}

public int getBufferGrouperMaxSize()
{
return bufferGrouperMaxSize;
Expand Down Expand Up @@ -383,8 +357,6 @@ public String toString()
{
return "GroupByQueryConfig{" +
"singleThreaded=" + singleThreaded +
", maxIntermediateRows=" + maxIntermediateRows +
", maxResults=" + maxResults +
", bufferGrouperMaxSize=" + bufferGrouperMaxSize +
", bufferGrouperMaxLoadFactor=" + bufferGrouperMaxLoadFactor +
", bufferGrouperInitialBuckets=" + bufferGrouperInitialBuckets +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -286,9 +286,6 @@ public HumanReadableBytes getMaxOnDiskStorage()
}
};
config.setSingleThreaded(false);
config.setMaxIntermediateRows(Integer.MAX_VALUE);
config.setMaxResults(Integer.MAX_VALUE);

DruidProcessingConfig druidProcessingConfig = new DruidProcessingConfig()
{
@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -557,8 +557,6 @@ public HumanReadableBytes getMaxOnDiskStorage()
}
};
config.setSingleThreaded(false);
config.setMaxIntermediateRows(Integer.MAX_VALUE);
config.setMaxResults(Integer.MAX_VALUE);

DruidProcessingConfig druidProcessingConfig = new DruidProcessingConfig()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -222,8 +222,6 @@ public HumanReadableBytes getMaxOnDiskStorage()
}
};
config.setSingleThreaded(false);
config.setMaxIntermediateRows(Integer.MAX_VALUE);
config.setMaxResults(Integer.MAX_VALUE);

DruidProcessingConfig druidProcessingConfig = new DruidProcessingConfig()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,7 @@ public class GroupByQueryConfigTest
private final ImmutableMap<String, String> CONFIG_MAP = ImmutableMap
.<String, String>builder()
.put("singleThreaded", "true")
.put("defaultStrategy", "v2")
.put("bufferGrouperInitialBuckets", "1")
.put("maxIntermediateRows", "2")
.put("maxResults", "3")
.put("defaultOnDiskStorage", "1M")
.put("maxOnDiskStorage", "4M")
.put("maxSelectorDictionarySize", "5")
Expand All @@ -52,8 +49,6 @@ public void testSerde()

Assert.assertEquals(true, config.isSingleThreaded());
Assert.assertEquals(1, config.getBufferGrouperInitialBuckets());
Assert.assertEquals(2, config.getMaxIntermediateRows());
Assert.assertEquals(3, config.getMaxResults());
Assert.assertEquals(4_000_000, config.getMaxOnDiskStorage().getBytes());
Assert.assertEquals(1_000_000, config.getDefaultOnDiskStorage().getBytes());
Assert.assertEquals(5, config.getConfiguredMaxSelectorDictionarySize());
Expand All @@ -76,8 +71,6 @@ public void testNoOverrides()

Assert.assertEquals(true, config2.isSingleThreaded());
Assert.assertEquals(1, config2.getBufferGrouperInitialBuckets());
Assert.assertEquals(2, config2.getMaxIntermediateRows());
Assert.assertEquals(3, config2.getMaxResults());
Assert.assertEquals(1_000_000, config2.getMaxOnDiskStorage().getBytes());
Assert.assertEquals(5, config2.getConfiguredMaxSelectorDictionarySize());
Assert.assertEquals(6_000_000, config2.getConfiguredMaxMergingDictionarySize());
Expand Down Expand Up @@ -108,8 +101,6 @@ public void testOverrides()

Assert.assertEquals(true, config2.isSingleThreaded());
Assert.assertEquals(1, config2.getBufferGrouperInitialBuckets());
Assert.assertEquals(2, config2.getMaxIntermediateRows());
Assert.assertEquals(2, config2.getMaxResults());
Assert.assertEquals(3_000_000, config2.getMaxOnDiskStorage().getBytes());
Assert.assertEquals(5 /* Can't override */, config2.getConfiguredMaxSelectorDictionarySize());
Assert.assertEquals(6_000_000 /* Can't override */, config2.getConfiguredMaxMergingDictionarySize());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,6 @@ public static Iterable<Object[]> constructorFeeder()
{
setUpClass();
GroupByQueryConfig config = new GroupByQueryConfig();
config.setMaxIntermediateRows(10000);
final GroupByQueryRunnerFactory factory = GroupByQueryRunnerTest.makeQueryRunnerFactory(config, BUFFER_POOLS);

final List<Object[]> constructors = new ArrayList<>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -269,8 +269,6 @@ public HumanReadableBytes getMaxOnDiskStorage()
}
};
config.setSingleThreaded(false);
config.setMaxIntermediateRows(Integer.MAX_VALUE);
config.setMaxResults(Integer.MAX_VALUE);

DruidProcessingConfig druidProcessingConfig = new DruidProcessingConfig()
{
Expand Down

0 comments on commit 7e5ed4d

Please sign in to comment.