Skip to content

Commit

Permalink
Update benchmark
Browse files Browse the repository at this point in the history
  • Loading branch information
Stephan202 committed Nov 27, 2024
1 parent a67e27c commit c3e519a
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,17 +37,17 @@
@OutputTimeUnit(TimeUnit.NANOSECONDS)
@State(Scope.Benchmark)
public class TracesBenchmark {
@Param({"0", "10", "100", "1000"})
@Param({"0", "1", "2"})
private int reactorLeadingLines;

@Param({"0", "10", "100", "1000"})
@Param({"0", "1", "2"})
private int trailingLines;

private String stackTrace;

@Setup(Level.Iteration)
public void setup() {
stackTrace = createLargeStackTrace(reactorLeadingLines, trailingLines);
stackTrace = createStackTrace(reactorLeadingLines, trailingLines);
}

@SuppressWarnings("unused")
Expand All @@ -56,7 +56,7 @@ public String measureThroughput() {
return Traces.extractOperatorAssemblyInformation(stackTrace);
}

private static String createLargeStackTrace(int reactorLeadingLines, int trailingLines) {
private static String createStackTrace(int reactorLeadingLines, int trailingLines) {
StringBuilder sb = new StringBuilder();
for (int i = 0; i < reactorLeadingLines; i++) {
sb.append("\tat reactor.core.publisher.Flux.someOperation(Flux.java:42)\n");
Expand Down

0 comments on commit c3e519a

Please sign in to comment.