Skip to content

Commit 0dfdf89

Browse files
committed
Use appropriate completion handler in PerfTestMulti scenarios
The tests run from PerfTestMulti would be running with MulticastSet.NoLimitCompletionHandler, so they would never stop. They now use the appropriate completion handler by relying on PerfTest#getCompletionHandler. Fixes #95
1 parent 47c17b0 commit 0dfdf89

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/main/java/com/rabbitmq/perf/SimpleScenario.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ public void run()
4646
throws IOException, InterruptedException, TimeoutException, NoSuchAlgorithmException, KeyManagementException, URISyntaxException, ExecutionException {
4747
this.stats = new SimpleScenarioStats(interval);
4848
for (MulticastParams p : params) {
49-
MulticastSet set = new MulticastSet(stats, factory, p, null, new MulticastSet.NoLimitCompletionHandler());
49+
MulticastSet set = new MulticastSet(stats, factory, p, null, PerfTest.getCompletionHandler(p));
5050
stats.setup(p);
5151
set.run();
5252
}

src/main/java/com/rabbitmq/perf/VaryingScenario.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ private void run(Variable[] variables, List<VariableValue> values) throws Except
6060
for (VariableValue value : values) {
6161
value.setup(p);
6262
}
63-
MulticastSet set = new MulticastSet(stats0, factory, p, null, new MulticastSet.NoLimitCompletionHandler());
63+
MulticastSet set = new MulticastSet(stats0, factory, p, null, PerfTest.getCompletionHandler(p));
6464
stats0.setup(p);
6565
set.run();
6666
for (VariableValue value : values) {

0 commit comments

Comments
 (0)