Skip to content

Commit

Permalink
Patch java versions to v1.32.0 (#862)
Browse files Browse the repository at this point in the history
  • Loading branch information
bryan-aguilar authored Feb 14, 2024
1 parent cb9f316 commit d0764a7
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 0 deletions.
25 changes: 25 additions & 0 deletions OTEL_Java_Version.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
diff --git a/java/dependencyManagement/build.gradle.kts b/java/dependencyManagement/build.gradle.kts
index 4d7087a..62dcbb7 100644
--- a/java/dependencyManagement/build.gradle.kts
+++ b/java/dependencyManagement/build.gradle.kts
@@ -9,16 +9,16 @@ plugins {
data class DependencySet(val group: String, val version: String, val modules: List<String>)

val DEPENDENCY_BOMS = listOf(
- "io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom-alpha:2.0.0-alpha",
- "org.apache.logging.log4j:log4j-bom:2.22.1",
- "software.amazon.awssdk:bom:2.23.7"
+ "io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom-alpha:1.32.0-alpha",
+ "org.apache.logging.log4j:log4j-bom:2.22.0",
+ "software.amazon.awssdk:bom:2.21.42"
)

val DEPENDENCIES = listOf(
"com.amazonaws:aws-lambda-java-core:1.2.3",
"com.amazonaws:aws-lambda-java-events:3.11.4",
"com.squareup.okhttp3:okhttp:4.12.0",
- "io.opentelemetry.javaagent:opentelemetry-javaagent:2.0.0"
+ "io.opentelemetry.javaagent:opentelemetry-javaagent:1.32.0"
)

javaPlatform {
11 changes: 11 additions & 0 deletions patch-upstream.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,15 @@ cp -rf adot/* opentelemetry-lambda/
# Get current repo path
CURRENT_DIR=$PWD

cd opentelemetry-lambda/java
# patch otel version on collector/go.mod
PATCH_JAVA_VERSION="../../OTEL_Java_Version.patch"

if [ -f $PATCH_JAVA_VERSION ]; then
patch -p2 < $PATCH_JAVA_VERSION;
fi
cd ../..

# Move to the upstream OTel Lambda Collector folder where we will build a
# collector used in each Lambda layer
cd opentelemetry-lambda/collector
Expand All @@ -30,6 +39,8 @@ if [ -f $PATCH_OTEL_VERSION ]; then
patch -p2 < $PATCH_OTEL_VERSION;
fi



# patch collector startup to remove HTTP and S3 confmap providers
# and set ADOT-specific BuildInfo
patch -p2 < ../../collector.patch
Expand Down

0 comments on commit d0764a7

Please sign in to comment.