Add bursty-load JMH benchmark for BatchSpanProcessor#8178
Add bursty-load JMH benchmark for BatchSpanProcessor#8178adp2201 wants to merge 1 commit intoopen-telemetry:mainfrom
Conversation
|
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8178 +/- ##
=========================================
Coverage 90.29% 90.29%
Complexity 7650 7650
=========================================
Files 843 843
Lines 23059 23059
Branches 2309 2309
=========================================
Hits 20822 20822
Misses 1519 1519
Partials 718 718 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Output on my machine doesn't show results for |
|
Thanks for flagging this. I reproduced the same output ( What I found:
What we can do about it:
Thoughts on this approach? |
I'm new to JMH aux counters so the onus will be on you to figure out how to use them appropriately to demonstrate the problem, and eventually show improvement. 🙂 Not sure if its useful to you, but BatchSpanProcessor already collects internal telemetry capturing some (all?) of these concepts. The metrics conform to the Consider if its possible / helpful to expose the metrics you want by setting up internal telemetry and reading it out in the JMH aux counter accessors. |
|
Thanks, this is really helpful context. I’d like to keep this PR focused and incorporate your suggestion directly:
And yes, I think a follow-up issue makes sense for anything broader we uncover (e.g., aligning aux-counter/reporting patterns across other BSP JMH benchmarks) so we can keep this PR small and still track the improvements. What do you think? |
Summary
BatchSpanProcessorBurstyLoadBenchmarkdropRatio,droppedSpans, andexportedSpansviaBatchSpanProcessorMetricsaux counterssdk/traceJMH sources)Motivation
This is a small, low-risk first increment for #7508: establish a reproducible benchmark harness before discussing any default semantic changes to
BatchSpanProcessor.Tests Run
Using Java 21:
./gradlew check./gradlew :sdk:trace:compileJmhJava :sdk:trace:checkstyleJmh./gradlew --no-configuration-cache -PjmhIncludeSingleClass=BatchSpanProcessorBurstyLoadBenchmark :sdk:trace:jmhNext Steps
Part of #7508.