Skip to content

Commit b62c526

Browse files
authored
Merge branch 'open-telemetry:main' into patch-1
2 parents 2cfe28e + 4b04296 commit b62c526

File tree

164 files changed

+1017
-512
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

164 files changed

+1017
-512
lines changed

.github/scripts/markdown-link-check-config.json

+3
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@
1919
},
2020
{
2121
"pattern": "^https://micrometer\\.io"
22+
},
23+
{
24+
"pattern": "^https://central\\.sonatype\\.com"
2225
}
2326
]
2427
}

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,7 @@ See [CONTRIBUTING.md](CONTRIBUTING.md).
152152
Triagers ([@open-telemetry/java-instrumentation-triagers](https://github.com/orgs/open-telemetry/teams/java-instrumentation-triagers)):
153153

154154
- [Gregor Zeitlinger](https://github.com/zeitlinger), Grafana Labs
155+
- [Jean Bisutti](https://github.com/jeanbisutti), Microsoft
155156

156157
Approvers ([@open-telemetry/java-instrumentation-approvers](https://github.com/orgs/open-telemetry/teams/java-instrumentation-approvers)):
157158

benchmark-overhead/build.gradle.kts

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ dependencies {
2525
testImplementation("com.squareup.okhttp3:okhttp:4.12.0")
2626
testImplementation("org.jooq:joox:2.0.0")
2727
testImplementation("com.jayway.jsonpath:json-path:2.8.0")
28-
testImplementation("org.slf4j:slf4j-simple:2.0.9")
28+
testImplementation("org.slf4j:slf4j-simple:2.0.11")
2929

3030
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine")
3131
}

conventions/build.gradle.kts

+2-2
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ dependencies {
6060
implementation("com.github.johnrengelman:shadow:8.1.1")
6161
implementation("org.apache.httpcomponents:httpclient:4.5.14")
6262
implementation("com.gradle.enterprise:com.gradle.enterprise.gradle.plugin:3.16.1")
63-
implementation("org.owasp:dependency-check-gradle:9.0.7")
63+
implementation("org.owasp:dependency-check-gradle:9.0.8")
6464
implementation("ru.vyarus:gradle-animalsniffer-plugin:1.7.1")
6565
// When updating, also update dependencyManagement/build.gradle.kts
6666
implementation("net.bytebuddy:byte-buddy-gradle-plugin:1.14.11")
@@ -73,5 +73,5 @@ dependencies {
7373
testImplementation(enforcedPlatform("org.junit:junit-bom:5.10.1"))
7474
testImplementation("org.junit.jupiter:junit-jupiter-api")
7575
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine")
76-
testImplementation("org.assertj:assertj-core:3.24.2")
76+
testImplementation("org.assertj:assertj-core:3.25.1")
7777
}

conventions/src/main/kotlin/otel.java-conventions.gradle.kts

+2-1
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,7 @@ codenarc {
407407
checkstyle {
408408
configFile = rootProject.file("buildscripts/checkstyle.xml")
409409
// this version should match the version of google_checks.xml used as basis for above configuration
410-
toolVersion = "10.12.6"
410+
toolVersion = "10.12.7"
411411
maxWarnings = 0
412412
}
413413

@@ -416,6 +416,7 @@ dependencyCheck {
416416
suppressionFile = "buildscripts/dependency-check-suppressions.xml"
417417
failBuildOnCVSS = 7.0f // fail on high or critical CVE
418418
nvd.apiKey = System.getenv("NVD_API_KEY")
419+
nvd.delay = 3500 // until next dependency check release (https://github.com/jeremylong/DependencyCheck/pull/6333)
419420
}
420421

421422
idea {

dependencyManagement/build.gradle.kts

+5-5
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ val dependencyVersions = hashMapOf<String, String>()
88
rootProject.extra["versions"] = dependencyVersions
99

1010
// this line is managed by .github/scripts/update-sdk-version.sh
11-
val otelSdkVersion = "1.33.0"
11+
val otelSdkVersion = "1.34.0"
1212
val otelSdkAlphaVersion = otelSdkVersion.replaceFirst("(-SNAPSHOT)?$".toRegex(), "-alpha$1")
1313

1414
// Need both BOM and groovy jars
@@ -39,12 +39,12 @@ val DEPENDENCY_BOMS = listOf(
3939

4040
val autoServiceVersion = "1.1.1"
4141
val autoValueVersion = "1.10.4"
42-
val errorProneVersion = "2.23.0"
42+
val errorProneVersion = "2.24.1"
4343
val byteBuddyVersion = "1.14.11"
4444
val asmVersion = "9.6"
4545
val jmhVersion = "1.37"
4646
val mockitoVersion = "4.11.0"
47-
val slf4jVersion = "2.0.9"
47+
val slf4jVersion = "2.0.11"
4848

4949
val CORE_DEPENDENCIES = listOf(
5050
"io.opentelemetry.semconv:opentelemetry-semconv:1.21.0-alpha",
@@ -84,7 +84,7 @@ val DEPENDENCIES = listOf(
8484
"com.github.stefanbirkner:system-lambda:1.2.1",
8585
"com.github.stefanbirkner:system-rules:1.19.0",
8686
"uk.org.webcompere:system-stubs-jupiter:2.0.3",
87-
"com.uber.nullaway:nullaway:0.10.18",
87+
"com.uber.nullaway:nullaway:0.10.19",
8888
"commons-beanutils:commons-beanutils:1.9.4",
8989
"commons-cli:commons-cli:1.6.0",
9090
"commons-codec:commons-codec:1.16.0",
@@ -98,7 +98,7 @@ val DEPENDENCIES = listOf(
9898
"io.netty:netty:3.10.6.Final",
9999
"io.opentelemetry.contrib:opentelemetry-aws-xray-propagator:1.28.0-alpha",
100100
"io.opentelemetry.proto:opentelemetry-proto:1.0.0-alpha",
101-
"org.assertj:assertj-core:3.24.2",
101+
"org.assertj:assertj-core:3.25.1",
102102
"org.awaitility:awaitility:4.2.0",
103103
"com.google.code.findbugs:annotations:3.0.1u2",
104104
"com.google.code.findbugs:jsr305:3.0.2",

docs/contributing/intellij-setup-and-troubleshooting.md

+10
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,16 @@ on which you are not actively working.
3131
Specifically, unload all modules, and then selectively load the modules on which you need to work.
3232
IntelliJ will prompt you to load additional modules on which the selected modules depend.
3333

34+
If you are working on a specific instrumentation, you can load only the modules for that instrumentation.
35+
For example, to load the modules for the Spring Boot autoconfigure instrumentation, run:
36+
37+
```shell
38+
./docs/contributing/selectModules.kts instrumentation/spring/spring-boot-autoconfigure/
39+
```
40+
41+
Install the [Kotlin executable](https://kotlinlang.org/docs/tutorials/command-line.html)
42+
if you don't have it already.
43+
3444
## Troubleshooting
3545

3646
Occasionally, Intellij gets confused, maybe due to the number of modules in this project,

docs/contributing/selectModules.kts

+83
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
#!/usr/bin/env kotlin
2+
3+
//install kotlin compiler: https://kotlinlang.org/docs/tutorials/command-line.html
4+
import java.io.File
5+
6+
val includeRegex = Regex("include\\(\"(.*?)\"\\)")
7+
val projectRegex = "project\\(\"([^\"]+)\"(, configuration = \".*\")?\\)".toRegex()
8+
val keepModules = mutableSetOf<Module>()
9+
var root = ""
10+
11+
main(args)
12+
13+
fun main(args: Array<String>) {
14+
if (args.isEmpty()) {
15+
println("Usage: ./docs/contributing/selectModules.kts instrumentation/spring/spring-boot-autoconfigure/ <module to include2> ...")
16+
return
17+
}
18+
19+
(args.map {
20+
moduleOfArg(
21+
File(File(it).absolutePath),
22+
"/" + it.trimStart('.', '/').trimEnd('/')
23+
)
24+
} + listOf(":javaagent"))
25+
.map { Module(it) }
26+
.forEach(Module::addSelfAndChildren)
27+
28+
File("$root/conventions/src/main/kotlin").listFiles()!!
29+
.filter { it.name.endsWith(".kts") }
30+
.forEach {
31+
children(it).forEach(Module::addSelfAndChildren)
32+
}
33+
34+
println("removing modules except:\n${keepModules.map { it.name }.sorted().joinToString("\n")}")
35+
36+
val target = File("$root/settings.gradle.kts")
37+
val text = target.readText().lines().flatMap { line ->
38+
includeRegex.matchEntire(line)?.let { it.groupValues[1] }?.let { module ->
39+
if (Module(module) in keepModules) {
40+
listOf(line)
41+
} else {
42+
emptyList()
43+
}
44+
} ?: listOf(line)
45+
46+
47+
}.joinToString("\n")
48+
target.writeText(text)
49+
}
50+
51+
data class Module(val name: String) {
52+
fun children(): List<Module> {
53+
val file = moduleFile()
54+
return children(file)
55+
}
56+
57+
private fun moduleFile(): File = File("$root/${name.replace(":", "/")}/build.gradle.kts")
58+
59+
fun addSelfAndChildren() {
60+
if (!keepModules.add(this)) {
61+
return
62+
}
63+
64+
children().forEach(Module::addSelfAndChildren)
65+
}
66+
}
67+
68+
fun moduleOfArg(file: File, name: String): String {
69+
val settings = File(file, "settings.gradle.kts")
70+
return if (settings.exists()) {
71+
root = file.absolutePath
72+
name.substringAfter(root).replace("/", ":")
73+
} else {
74+
moduleOfArg(file.parentFile, name)
75+
}
76+
}
77+
78+
fun children(file: File) = file.readText().lines().flatMap { line ->
79+
projectRegex.find(line)?.let { it.groupValues[1] }?.let { module ->
80+
listOf(Module(module))
81+
} ?: emptyList()
82+
}
83+

0 commit comments

Comments
 (0)