Skip to content

Commit 0519083

Browse files
committed
feat(profiling): Add benchmarks for OTLP/P converter
1 parent 6743cc4 commit 0519083

File tree

10 files changed

+2003
-15
lines changed

10 files changed

+2003
-15
lines changed

dd-java-agent/agent-profiling/profiling-otel/build.gradle.kts

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,42 @@
11
plugins {
22
`java-library`
3+
id("me.champeau.jmh")
34
}
45

56
apply(from = "$rootDir/gradle/java.gradle")
67

8+
jmh {
9+
jmhVersion = libs.versions.jmh.get()
10+
11+
// Fast benchmarks by default (essential hot-path only)
12+
// Run with: ./gradlew jmh
13+
// Override includes with: ./gradlew jmh -Pjmh.includes=".*"
14+
includes = listOf(".*intern(String|Function|Stack)", ".*convertStackTrace")
15+
16+
// Override parameters with: -Pjmh.params="uniqueEntries=1000,hitRate=0.0"
17+
}
18+
19+
// Full benchmark suite with all benchmarks and default parameters
20+
// Estimated time: ~40 minutes
21+
tasks.register<JavaExec>("jmhFull") {
22+
group = "benchmark"
23+
description = "Runs the full JMH benchmark suite (all benchmarks, all parameters)"
24+
dependsOn(tasks.named("jmhCompileGeneratedClasses"))
25+
26+
classpath = sourceSets["jmh"].runtimeClasspath
27+
mainClass.set("org.openjdk.jmh.Main")
28+
args = listOf("-rf", "json")
29+
}
30+
31+
repositories {
32+
maven {
33+
url = uri("https://s01.oss.sonatype.org/content/repositories/snapshots/")
34+
mavenContent {
35+
snapshotsOnly()
36+
}
37+
}
38+
}
39+
740
dependencies {
841
implementation("io.btrace", "jafar-parser", "0.0.1-SNAPSHOT")
942
implementation(project(":internal-api"))

0 commit comments

Comments
 (0)