Skip to content

Commit 3b23e6b

Browse files
committed
Merge branch 'main' of github.com:open-telemetry/opentelemetry-java-instrumentation into jmx-jetty
2 parents f09492a + 4b184e7 commit 3b23e6b

File tree

201 files changed

+3762
-1974
lines changed

Some content is hidden

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

201 files changed

+3762
-1974
lines changed

.github/workflows/codeql.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ jobs:
5757
cache-read-only: ${{ github.event_name == 'pull_request' }}
5858

5959
- name: Initialize CodeQL
60-
uses: github/codeql-action/init@39edc492dbe16b1465b0cafca41432d857bdb31a # v3.29.1
60+
uses: github/codeql-action/init@181d5eefc20863364f96762470ba6f862bdef56b # v3.29.2
6161
with:
6262
languages: ${{ matrix.language }}
6363
# using "latest" helps to keep up with the latest Kotlin support
@@ -73,6 +73,6 @@ jobs:
7373
run: ./gradlew assemble -x javadoc -x :instrumentation:quarkus-resteasy-reactive:quarkus3-testing:quarkusGenerateCodeDev -x :instrumentation:quarkus-resteasy-reactive:quarkus2-testing:quarkusGenerateCodeDev --no-build-cache --no-daemon
7474

7575
- name: Perform CodeQL analysis
76-
uses: github/codeql-action/analyze@39edc492dbe16b1465b0cafca41432d857bdb31a # v3.29.1
76+
uses: github/codeql-action/analyze@181d5eefc20863364f96762470ba6f862bdef56b # v3.29.2
7777
with:
7878
category: "/language:${{matrix.language}}"

.github/workflows/ossf-scorecard.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,6 @@ jobs:
4242
# Upload the results to GitHub's code scanning dashboard (optional).
4343
# Commenting out will disable upload of results to your repo's Code Scanning dashboard
4444
- name: "Upload to code-scanning"
45-
uses: github/codeql-action/upload-sarif@39edc492dbe16b1465b0cafca41432d857bdb31a # v3.29.1
45+
uses: github/codeql-action/upload-sarif@181d5eefc20863364f96762470ba6f862bdef56b # v3.29.2
4646
with:
4747
sarif_file: results.sarif

.github/workflows/release.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,8 @@ jobs:
100100
SONATYPE_KEY: ${{ secrets.SONATYPE_KEY }}
101101
GPG_PRIVATE_KEY: ${{ secrets.GPG_PRIVATE_KEY }}
102102
GPG_PASSWORD: ${{ secrets.GPG_PASSWORD }}
103-
run: ./gradlew assemble spdxSbom publishToSonatype closeAndReleaseSonatypeStagingRepository
103+
# run: ./gradlew assemble spdxSbom publishToSonatype closeAndReleaseSonatypeStagingRepository
104+
run: ./gradlew assemble spdxSbom publishAllPublicationToReleaseRepoRepository generateReleaseBundle uploadReleaseBundle
104105

105106
- name: Build and publish gradle plugins
106107
env:

benchmark-overhead/Dockerfile.petclinic

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM eclipse-temurin:11.0.27_6-jdk@sha256:cc77e8b834bfa18f4bf93d1649e27256213490168b35d7c72a2b92545763fab8 as app-build
1+
FROM eclipse-temurin:11.0.27_6-jdk@sha256:2fd4e5e0ba72f725016e757a5688ce14fda6a792da566fca62ef6ff73f50df35 as app-build
22

33
# This is the base image that will contain a built version of the spring-petclinic-rest
44
# application. Installing the dependencies and maven compiling the application is time

benchmark-overhead/build.gradle.kts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
plugins {
22
id("java")
3-
id("com.diffplug.spotless") version "7.0.4"
3+
id("com.diffplug.spotless") version "7.1.0"
44
}
55

66
spotless {
@@ -16,13 +16,13 @@ repositories {
1616
}
1717

1818
dependencies {
19-
implementation(enforcedPlatform("org.junit:junit-bom:5.13.2"))
19+
implementation(enforcedPlatform("org.junit:junit-bom:5.13.3"))
2020

2121
testImplementation("org.testcontainers:testcontainers:1.21.3")
2222
testImplementation("org.testcontainers:postgresql:1.21.3")
2323
testImplementation("org.junit.jupiter:junit-jupiter-api")
2424
testImplementation("org.junit.jupiter:junit-jupiter-params")
25-
testImplementation("com.squareup.okhttp3:okhttp:4.12.0")
25+
testImplementation("com.squareup.okhttp3:okhttp:5.1.0")
2626
testImplementation("org.jooq:joox:2.0.1")
2727
testImplementation("com.jayway.jsonpath:json-path:2.9.0")
2828
testImplementation("org.slf4j:slf4j-simple:2.0.17")

benchmark-overhead/gradle/wrapper/gradle-wrapper.properties

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionSha256Sum=7197a12f450794931532469d4ff21a59ea2c1cd59a3ec3f89c035c3c420a6999
4-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.2-bin.zip
3+
distributionSha256Sum=bd71102213493060956ec229d946beee57158dbd89d0e62b91bca0fa2c5f3531
4+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
55
networkTimeout=10000
66
validateDistributionUrl=true
77
zipStoreBase=GRADLE_USER_HOME

build.gradle.kts

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1+
import okhttp3.MediaType.Companion.toMediaType
2+
import okhttp3.OkHttpClient
3+
import okhttp3.RequestBody.Companion.asRequestBody
14
import java.time.Duration
5+
import java.util.Base64
26

37
plugins {
48
id("idea")
@@ -16,6 +20,12 @@ plugins {
1620
id("org.graalvm.buildtools.native") apply false
1721
}
1822

23+
buildscript {
24+
dependencies {
25+
classpath("com.squareup.okhttp3:okhttp:5.1.0")
26+
}
27+
}
28+
1929
apply(from = "version.gradle.kts")
2030

2131
nexusPublishing {
@@ -111,6 +121,8 @@ if (gradle.startParameter.taskNames.contains("listTestsInPartition")) {
111121
}
112122

113123
tasks {
124+
val stableVersion = version.toString().replace("-alpha", "")
125+
114126
val generateFossaConfiguration by registering {
115127
group = "Help"
116128
description = "Generate .fossa.yml configuration file"
@@ -141,4 +153,47 @@ tasks {
141153
}
142154
}
143155
}
156+
157+
val generateReleaseBundle by registering(Zip::class) {
158+
dependsOn(getTasksByName("publishAllPublicationToReleaseRepoRepository", true))
159+
from("releaseRepo")
160+
161+
exclude("**/maven-metadata.*")
162+
duplicatesStrategy = DuplicatesStrategy.FAIL
163+
includeEmptyDirs = false
164+
archiveFileName.set("release-bundle-$stableVersion.zip")
165+
}
166+
167+
val uploadReleaseBundle by registering {
168+
dependsOn(generateReleaseBundle)
169+
170+
val username = System.getenv("SONATYPE_USER") ?: throw GradleException("Sonatype user not set")
171+
val password = System.getenv("SONATYPE_KEY") ?: throw GradleException("Sonatype key not set")
172+
val token = Base64.getEncoder().encodeToString("$username:$password".toByteArray())
173+
174+
var query = "?name=opentelemetry-java-instrumentation-$stableVersion"
175+
query += "&publishingType=AUTOMATIC"
176+
177+
doFirst {
178+
val bundle = generateReleaseBundle.get().outputs.files.singleFile
179+
val httpClient = OkHttpClient()
180+
181+
val request = okhttp3.Request.Builder()
182+
.url("https://central.sonatype.com/api/v1/publisher/upload$query")
183+
.post(
184+
okhttp3.MultipartBody.Builder().addFormDataPart(
185+
"bundle",
186+
bundle.name,
187+
bundle.asRequestBody("application/zip".toMediaType())
188+
).build()
189+
)
190+
.header("authorization", "Bearer $token")
191+
.build()
192+
193+
httpClient.newCall(request).execute().use { response ->
194+
if (response.code != 201) throw GradleException("Unexpected response status ${response.code} while uploading the release bundle")
195+
println("Uploaded deployment ${response.body.string()}")
196+
}
197+
}
198+
}
144199
}

conventions/build.gradle.kts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
plugins {
22
`kotlin-dsl`
33
// When updating, update below in dependencies too
4-
id("com.diffplug.spotless") version "7.0.4"
4+
id("com.diffplug.spotless") version "7.1.0"
55
}
66

77
spotless {
@@ -54,7 +54,7 @@ dependencies {
5454
implementation("org.apache.maven:maven-aether-provider:3.3.9")
5555

5656
// When updating, update above in plugins too
57-
implementation("com.diffplug.spotless:spotless-plugin-gradle:7.0.4")
57+
implementation("com.diffplug.spotless:spotless-plugin-gradle:7.1.0")
5858
implementation("com.google.guava:guava:33.4.8-jre")
5959
implementation("gradle.plugin.com.google.protobuf:protobuf-gradle-plugin:0.8.18")
6060
implementation("com.gradleup.shadow:shadow-gradle-plugin:8.3.8")
@@ -71,7 +71,7 @@ dependencies {
7171
implementation("net.ltgt.gradle:gradle-nullaway-plugin:2.2.0")
7272
implementation("me.champeau.gradle:japicmp-gradle-plugin:0.4.6")
7373

74-
testImplementation(enforcedPlatform("org.junit:junit-bom:5.13.2"))
74+
testImplementation(enforcedPlatform("org.junit:junit-bom:5.13.3"))
7575
testImplementation("org.junit.jupiter:junit-jupiter-api")
7676
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine")
7777
testImplementation("org.assertj:assertj-core:3.27.3")

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

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,13 @@ publishing {
6565
}
6666
}
6767
}
68+
69+
repositories {
70+
maven {
71+
name = "ReleaseRepo"
72+
url = File(project.rootDir.path, "releaseRepo").toURI()
73+
}
74+
}
6875
}
6976

7077
fun artifactPrefix(p: Project, archivesBaseName: String): String {

dependencyManagement/build.gradle.kts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ data class DependencySet(val group: String, val version: String, val modules: Li
66

77
// this line is managed by .github/scripts/update-sdk-version.sh
88
val otelSdkVersion = "1.51.0"
9-
val otelContribVersion = "1.46.0-alpha"
9+
val otelContribVersion = "1.47.0-alpha"
1010
val otelSdkAlphaVersion = otelSdkVersion.replaceFirst("(-SNAPSHOT)?$".toRegex(), "-alpha$1")
1111

1212
// Need both BOM and groovy jars
@@ -38,7 +38,7 @@ val DEPENDENCY_BOMS = listOf(
3838

3939
val autoServiceVersion = "1.1.1"
4040
val autoValueVersion = "1.11.0"
41-
val errorProneVersion = "2.39.0"
41+
val errorProneVersion = "2.40.0"
4242
val byteBuddyVersion = "1.17.6"
4343
val asmVersion = "9.8"
4444
val jmhVersion = "1.37"
@@ -81,7 +81,7 @@ val CORE_DEPENDENCIES = listOf(
8181
// There are dependencies included here that appear to have no usages, but are maintained at
8282
// this top level to help consistently satisfy large numbers of transitive dependencies.
8383
val DEPENDENCIES = listOf(
84-
"org.junit.jupiter:junit-jupiter-api:5.13.2",
84+
"org.junit.jupiter:junit-jupiter-api:5.13.3",
8585
"org.spockframework:spock-core:2.4-M6-groovy-4.0",
8686
"org.spockframework:spock-junit4:2.4-M6-groovy-4.0",
8787

@@ -100,7 +100,7 @@ val DEPENDENCIES = listOf(
100100
"commons-io:commons-io:2.19.0",
101101
"commons-lang:commons-lang:2.6",
102102
"commons-logging:commons-logging:1.3.5",
103-
"commons-validator:commons-validator:1.9.0",
103+
"commons-validator:commons-validator:1.10.0",
104104
"io.netty:netty:3.10.6.Final",
105105
"io.opentelemetry.contrib:opentelemetry-azure-resources:${otelContribVersion}",
106106
"io.opentelemetry.contrib:opentelemetry-aws-resources:${otelContribVersion}",
@@ -120,7 +120,7 @@ val DEPENDENCIES = listOf(
120120
"org.junit-pioneer:junit-pioneer:1.9.1",
121121
"org.objenesis:objenesis:3.4",
122122
"javax.validation:validation-api:2.0.1.Final",
123-
"org.snakeyaml:snakeyaml-engine:2.9",
123+
"org.snakeyaml:snakeyaml-engine:2.10",
124124
"org.elasticmq:elasticmq-rest-sqs_2.13:1.6.12"
125125
)
126126

0 commit comments

Comments
 (0)