Skip to content

Commit

Permalink
fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
sixpluszero committed Jan 16, 2025
1 parent 1858d1b commit 8019ada
Showing 1 changed file with 7 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ public void throttlerSwitchTest() throws IOException {
ConcurrentHashMap<String, StoreIngestionTask> tasks = new ConcurrentHashMap<>();
tasks.put("non_current_version_task", nonCurrentVersionTask);

IngestionThrottler throttler = new IngestionThrottler(true, serverConfig, () -> tasks, 10, TimeUnit.MILLISECONDS);
IngestionThrottler throttler =
new IngestionThrottler(true, serverConfig, () -> tasks, 10, TimeUnit.MILLISECONDS, null);
TestUtils.waitForNonDeterministicAssertion(3, TimeUnit.SECONDS, () -> {
assertFalse(
throttler.isUsingSpeedupThrottler(),
Expand Down Expand Up @@ -70,7 +71,7 @@ public void throttlerSwitchTest() throws IOException {

tasks.clear();
IngestionThrottler throttlerForNonDaVinciClient =
new IngestionThrottler(false, serverConfig, () -> tasks, 10, TimeUnit.MILLISECONDS);
new IngestionThrottler(false, serverConfig, () -> tasks, 10, TimeUnit.MILLISECONDS, null);
tasks.put("current_version_bootstrapping_task", currentVersionBootstrappingTask);
tasks.put("current_version_completed_task", currentVersionCompletedTask);
TestUtils.waitForNonDeterministicAssertion(3, TimeUnit.SECONDS, () -> {
Expand All @@ -85,11 +86,11 @@ public void throttlerSwitchTest() throws IOException {
@Test
public void testDifferentThrottler() {
VeniceServerConfig serverConfig = mock(VeniceServerConfig.class);
doReturn(100l).when(serverConfig).getKafkaFetchQuotaRecordPerSecond();
doReturn(60l).when(serverConfig).getKafkaFetchQuotaTimeWindow();
doReturn(1024l).when(serverConfig).getKafkaFetchQuotaBytesPerSecond();
doReturn(100L).when(serverConfig).getKafkaFetchQuotaRecordPerSecond();
doReturn(60L).when(serverConfig).getKafkaFetchQuotaTimeWindow();
doReturn(1024L).when(serverConfig).getKafkaFetchQuotaBytesPerSecond();
IngestionThrottler ingestionThrottler =
new IngestionThrottler(true, serverConfig, () -> Collections.emptyMap(), 10, TimeUnit.MILLISECONDS);
new IngestionThrottler(true, serverConfig, () -> Collections.emptyMap(), 10, TimeUnit.MILLISECONDS, null);
EventThrottler throttlerForAAWCLeader = mock(EventThrottler.class);
EventThrottler throttlerForCurrentVersionAAWCLeader = mock(EventThrottler.class);
EventThrottler throttlerForCurrentVersionNonAAWCLeader = mock(EventThrottler.class);
Expand Down

0 comments on commit 8019ada

Please sign in to comment.