Skip to content

Commit

Permalink
Update java dependencies to 1.30.0
Browse files Browse the repository at this point in the history
Signed-off-by: Raphael Silva <[email protected]>
  • Loading branch information
rapphil committed Oct 10, 2023
1 parent 3c90872 commit 4f515b0
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 18 deletions.
6 changes: 3 additions & 3 deletions java/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ val javaagentDependency by configurations.creating {
}

dependencies {
compileOnly(platform("io.opentelemetry:opentelemetry-bom:1.29.0"))
compileOnly(platform("io.opentelemetry:opentelemetry-bom-alpha:1.29.0-alpha"))
compileOnly(platform("io.opentelemetry:opentelemetry-bom:1.30.0"))
compileOnly(platform("io.opentelemetry:opentelemetry-bom-alpha:1.30.0-alpha"))
// Already included in wrapper so compileOnly
compileOnly("io.opentelemetry:opentelemetry-sdk-extension-autoconfigure-spi")
compileOnly("io.opentelemetry:opentelemetry-sdk-extension-aws")
javaagentDependency("software.amazon.opentelemetry:aws-opentelemetry-agent:1.29.0-adot-lambda1")
javaagentDependency("software.amazon.opentelemetry:aws-opentelemetry-agent:1.30.0-adot-lambda1")
}

tasks.register<Copy>("download") {
Expand Down
8 changes: 5 additions & 3 deletions java/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,12 @@ SOURCEDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"


## revert https://github.com/open-telemetry/opentelemetry-java-instrumentation/pull/7970
OTEL_VERSION="1.30.0"
ADOT_VERSION="1.30.0"

git clone https://github.com/open-telemetry/opentelemetry-java-instrumentation.git
pushd opentelemetry-java-instrumentation
git checkout v1.29.0 -b tag-v1.29.0
git checkout v${OTEL_VERSION} -b tag-v${OTEL_VERSION}
patch -p1 < "$SOURCEDIR"/../patches/opentelemetry-java-instrumentation.patch
git add -A
git commit -m "Create patch version"
Expand All @@ -21,11 +23,11 @@ git clone https://github.com/aws-observability/aws-otel-java-instrumentation.git

pushd aws-otel-java-instrumentation

git checkout v1.29.0 -b tag-v1.29.0
git checkout v${ADOT_VERSION} -b tag-v${ADOT_VERSION}
patch -p1 < "${SOURCEDIR}"/../patches/aws-otel-java-instrumentation.patch
git add -A
git commit -a -m "Create patch version"
CI=false ./gradlew publishToMavenLocal -Prelease.version=1.29.0-adot-lambda1
CI=false ./gradlew publishToMavenLocal -Prelease.version=${ADOT_VERSION}-adot-lambda1
popd

rm -rf aws-otel-java-instrumentation
Expand Down
2 changes: 1 addition & 1 deletion opentelemetry-lambda
6 changes: 3 additions & 3 deletions patches/aws-otel-java-instrumentation.patch
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ index b7226fb..f1658cd 100644
val TEST_SNAPSHOTS = rootProject.findProperty("testUpstreamSnapshots") == "true"

// This is the version of the upstream instrumentation BOM
-val otelVersion = "1.29.0"
+val otelVersion = "1.29.0-adot-lambda1"
val otelSnapshotVersion = "1.30.0"
-val otelVersion = "1.30.0"
+val otelVersion = "1.30.0-adot-lambda1"
val otelSnapshotVersion = "1.31.0"
val otelAlphaVersion = if (!TEST_SNAPSHOTS) "$otelVersion-alpha" else "$otelSnapshotVersion-alpha-SNAPSHOT"
val otelJavaAgentVersion = if (!TEST_SNAPSHOTS) otelVersion else "$otelSnapshotVersion-SNAPSHOT"
8 changes: 4 additions & 4 deletions patches/opentelemetry-java-instrumentation.patch
Original file line number Diff line number Diff line change
Expand Up @@ -604,10 +604,10 @@ index cc1414c0bf..db8a59b046 100644
--- a/version.gradle.kts
+++ b/version.gradle.kts
@@ -1,5 +1,5 @@
-val stableVersion = "1.29.0"
-val alphaVersion = "1.29.0-alpha"
+val stableVersion = "1.29.0-adot-lambda1"
+val alphaVersion = "1.29.0-adot-lambda1-alpha"
-val stableVersion = "1.30.0"
-val alphaVersion = "1.30.0-alpha"
+val stableVersion = "1.30.0-adot-lambda1"
+val alphaVersion = "1.30.0-adot-lambda1-alpha"

allprojects {
if (findProperty("otel.stable") != "true") {
8 changes: 4 additions & 4 deletions patches/opentelemetry-lambda_java.patch
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,17 @@ index b0ec233..5c2f919 100644
data class DependencySet(val group: String, val version: String, val modules: List<String>)

val DEPENDENCY_BOMS = listOf(
- "io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom-alpha:1.29.0-alpha",
+ "io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom-alpha:1.29.0-adot-lambda1-alpha",
- "io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom-alpha:1.30.0-alpha",
+ "io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom-alpha:1.30.0-adot-lambda1-alpha",
"org.apache.logging.log4j:log4j-bom:2.20.0",
"software.amazon.awssdk:bom:2.20.69"
)
@@ -18,7 +18,7 @@ val DEPENDENCIES = listOf(
"com.amazonaws:aws-lambda-java-core:1.2.2",
"com.amazonaws:aws-lambda-java-events:3.11.2",
"com.squareup.okhttp3:okhttp:4.11.0",
- "io.opentelemetry.javaagent:opentelemetry-javaagent:1.29.0"
+ "io.opentelemetry.javaagent:opentelemetry-javaagent:1.29.0-adot-lambda1"
- "io.opentelemetry.javaagent:opentelemetry-javaagent:1.30.0"
+ "io.opentelemetry.javaagent:opentelemetry-javaagent:1.30.0-adot-lambda1"
)

javaPlatform {

0 comments on commit 4f515b0

Please sign in to comment.