Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2,876 changes: 430 additions & 2,446 deletions OTEL_Version.patch

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions adot/python/src/template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ Resources:
- python3.9
- python3.10
- python3.11
- python3.12
- python3.13
Metadata:
BuildMethod: makefile
api:
Expand Down
8 changes: 4 additions & 4 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.42.0"))
compileOnly(platform("io.opentelemetry:opentelemetry-bom-alpha:1.42.0-alpha"))
compileOnly(platform("io.opentelemetry:opentelemetry-bom:1.32.0"))
compileOnly(platform("io.opentelemetry:opentelemetry-bom-alpha:1.32.0-alpha"))
// Already included in wrapper so compileOnly
compileOnly("io.opentelemetry:opentelemetry-sdk-extension-autoconfigure-spi")
compileOnly("io.opentelemetry:opentelemetry-sdk-extension-aws:1.19.0")
javaagentDependency("software.amazon.opentelemetry:aws-opentelemetry-agent:2.10.0")
compileOnly("io.opentelemetry:opentelemetry-sdk-extension-aws")
javaagentDependency("software.amazon.opentelemetry:aws-opentelemetry-agent:1.32.0-adot-lambda1")
}

tasks.register<Copy>("download") {
Expand Down
30 changes: 30 additions & 0 deletions java/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,36 @@

SOURCEDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"


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

git clone https://github.com/open-telemetry/opentelemetry-java-instrumentation.git
pushd opentelemetry-java-instrumentation
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"
./gradlew publishToMavenLocal
popd

rm -rf opentelemetry-java-instrumentation


git clone https://github.com/aws-observability/aws-otel-java-instrumentation.git

pushd aws-otel-java-instrumentation

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=${ADOT_VERSION}-adot-lambda1
popd

rm -rf aws-otel-java-instrumentation

# Build collector

pushd ../opentelemetry-lambda/collector || exit
Expand Down
2 changes: 1 addition & 1 deletion java/scripts/otel-handler
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

export OTEL_INSTRUMENTATION_AWS_SDK_EXPERIMENTAL_SPAN_ATTRIBUTES=true

export OTEL_PROPAGATORS="${OTEL_PROPAGATORS:xray-lambda,tracecontext,b3,b3multi}"
export OTEL_PROPAGATORS="${OTEL_PROPAGATORS:-xray,tracecontext,b3,b3multi}"

# Temporarily set OTEL_SERVICE_NAME variable to work around but in javaagent not handling
# OTEL_RESOURCE_ATTRIBUTES as set in otel-handler-upstream. It doesn't hurt to apply this
Expand Down
2 changes: 1 addition & 1 deletion java/scripts/otel-proxy-handler
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@

export OTEL_INSTRUMENTATION_AWS_SDK_EXPERIMENTAL_SPAN_ATTRIBUTES=true

export OTEL_PROPAGATORS="${OTEL_PROPAGATORS:xray-lambda,tracecontext,b3,b3multi}"
export OTEL_PROPAGATORS="${OTEL_PROPAGATORS:-xray,tracecontext,b3,b3multi}"

source /opt/otel-proxy-handler-upstream
2 changes: 1 addition & 1 deletion java/scripts/otel-stream-handler
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@

export OTEL_INSTRUMENTATION_AWS_SDK_EXPERIMENTAL_SPAN_ATTRIBUTES=true

export OTEL_PROPAGATORS="${OTEL_PROPAGATORS:xray-lambda,tracecontext,b3,b3multi}"
export OTEL_PROPAGATORS="${OTEL_PROPAGATORS:-xray,tracecontext,b3,b3multi}"

source /opt/otel-stream-handler-upstream
4 changes: 1 addition & 3 deletions nodejs/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@ mv ./packages/layer/build/workspace/otel-handler ./packages/layer/build/workspac
cp "$SOURCEDIR"/scripts/otel-handler ./packages/layer/build/workspace/otel-handler
# This assumes that generators and propagators does not have additional dependencies outside of normal OTel ones.
# It's inconceivable for this to ever be incorrect.
cp -r "$SOURCEDIR"/wrapper-adot/node_modules/@opentelemetry/id-generator-aws-xray ./packages/layer/build/workspace/nodejs/node_modules/@opentelemetry
cp -r "$SOURCEDIR"/wrapper-adot/node_modules/@opentelemetry/propagator-aws-xray ./packages/layer/build/workspace/nodejs/node_modules/@opentelemetry
cp -r "$SOURCEDIR"/wrapper-adot/node_modules/@opentelemetry/propagator-b3 ./packages/layer/build/workspace/nodejs/node_modules/@opentelemetry
cp -r "$SOURCEDIR"/wrapper-adot/node_modules/@opentelemetry ./packages/layer/build/workspace/node_modules/
cp "$SOURCEDIR"/wrapper-adot/build/src/adot-extension.* ./packages/layer/build/workspace/

cd ./packages/layer/build/workspace || exit
Expand Down
18 changes: 18 additions & 0 deletions nodejs/scripts/otel-handler
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,24 @@

export NODE_OPTIONS="--require /opt/adot-extension.js ${NODE_OPTIONS}"

# If both OTEL_NODE_ENABLED_INSTRUMENTATIONS and OTEL_NODE_DISABLED_INSTRUMENTATIONS are not configured,
# set OTEL_NODE_ENABLED_INSTRUMENTATIONS="aws-sdk,aws-lambda,http"
if [ -z "${OTEL_NODE_ENABLED_INSTRUMENTATIONS}" ] && [ -z "${OTEL_NODE_DISABLED_INSTRUMENTATIONS}" ]; then
export OTEL_NODE_ENABLED_INSTRUMENTATIONS="aws-sdk,aws-lambda,http"

# Else if OTEL_NODE_ENABLED_INSTRUMENTATIONS is configured and OTEL_NODE_DISABLED_INSTRUMENTATIONS is not,
# append OTEL_NODE_ENABLED_INSTRUMENTATIONS with "aws-lambda,http"
elif [ -n "${OTEL_NODE_ENABLED_INSTRUMENTATIONS}" ] && [ -z "${OTEL_NODE_DISABLED_INSTRUMENTATIONS}" ]; then
export OTEL_NODE_ENABLED_INSTRUMENTATIONS="${OTEL_NODE_ENABLED_INSTRUMENTATIONS},aws-lambda,http"

# Else if both OTEL_NODE_ENABLED_INSTRUMENTATIONS and OTEL_NODE_DISABLED_INSTRUMENTATIONS are configured,
# append OTEL_NODE_ENABLED_INSTRUMENTATIONS with "aws-lambda,http"
elif [ -n "${OTEL_NODE_ENABLED_INSTRUMENTATIONS}" ] && [ -n "${OTEL_NODE_DISABLED_INSTRUMENTATIONS}" ]; then
export OTEL_NODE_ENABLED_INSTRUMENTATIONS="${OTEL_NODE_ENABLED_INSTRUMENTATIONS},aws-lambda,http"

# Else do nothing
fi

if [[ -z "$OTEL_PROPAGATORS" ]]; then
export OTEL_PROPAGATORS="tracecontext,baggage,xray-lambda"
fi
Expand Down
12 changes: 6 additions & 6 deletions nodejs/wrapper-adot/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@
"typescript": "5.8.3"
},
"dependencies": {
"@opentelemetry/core": "^2.0.0",
"@opentelemetry/id-generator-aws-xray": "^2.0.0",
"@opentelemetry/sdk-trace-node": "^2.0.0",
"@opentelemetry/propagator-aws-xray": "^2.0.0",
"@opentelemetry/propagator-b3": "^2.0.0",
"@opentelemetry/sdk-trace-base": "^2.0.0"
"@opentelemetry/core": "^1.30.0",
"@opentelemetry/id-generator-aws-xray": "^1.2.3",
"@opentelemetry/sdk-trace-node": "^1.30.0",
"@opentelemetry/propagator-aws-xray": "^1.26.2",
"@opentelemetry/propagator-b3": "^1.30.0",
"@opentelemetry/sdk-trace-base": "^1.30.0"
}
}
2 changes: 1 addition & 1 deletion opentelemetry-lambda
Submodule opentelemetry-lambda updated 40 files
+1 −1 .github/workflows/release-layer-nodejs.yml
+1 −1 .github/workflows/release-layer-ruby.yml
+2 −3 README.md
+104 −135 collector/go.mod
+219 −1,017 collector/go.sum
+20 −20 collector/internal/tools/go.mod
+42 −42 collector/internal/tools/go.sum
+94 −125 collector/lambdacomponents/go.mod
+207 −1,005 collector/lambdacomponents/go.sum
+19 −19 collector/processor/coldstartprocessor/go.mod
+38 −38 collector/processor/coldstartprocessor/go.sum
+22 −24 collector/processor/decoupleprocessor/go.mod
+44 −49 collector/processor/decoupleprocessor/go.sum
+21 −26 collector/receiver/telemetryapireceiver/go.mod
+45 −50 collector/receiver/telemetryapireceiver/go.sum
+2 −2 go/sample-apps/function/go.mod
+4 −4 go/sample-apps/function/go.sum
+3 −3 java/dependencyManagement/build.gradle.kts
+515 −464 nodejs/package-lock.json
+1 −1 nodejs/package.json
+4,016 −0 nodejs/packages/layer/package-lock.json
+48 −48 nodejs/packages/layer/package.json
+1 −0 nodejs/packages/layer/scripts/version.js
+24 −0 nodejs/packages/layer/src/LambdaTracerProvider.ts
+30 −77 nodejs/packages/layer/src/wrapper.ts
+1 −1 nodejs/packages/layer/test/handler.spec.mjs
+1 −1 nodejs/packages/layer/test/handler.spec.ts
+2 −57 nodejs/packages/layer/test/wrapper.spec.ts
+17 −18 nodejs/sample-apps/aws-sdk/package-lock.json
+3 −3 nodejs/sample-apps/aws-sdk/package.json
+1 −1 nodejs/tsconfig.base.json
+2 −2 nodejs/tsconfig.esm.json
+2 −2 python/src/otel/otel_sdk/nodeps-requirements.txt
+33 −33 python/src/otel/otel_sdk/requirements.txt
+1 −1 python/src/otel/tests/nodeps-requirements.txt
+3 −3 python/src/otel/tests/requirements.txt
+17 −16 ruby/README.md
+2 −18 ruby/src/otel/Dockerfile
+1 −1 ruby/src/otel/layer/Gemfile
+6 −34 ruby/src/otel/layer/wrapper.rb
13 changes: 13 additions & 0 deletions patches/aws-otel-java-instrumentation.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/dependencyManagement/build.gradle.kts b/dependencyManagement/build.gradle.kts
index 9493189..6090207 100644
--- a/dependencyManagement/build.gradle.kts
+++ b/dependencyManagement/build.gradle.kts
@@ -27,7 +27,7 @@ data class DependencySet(val group: String, val version: String, val modules: Li
val TEST_SNAPSHOTS = rootProject.findProperty("testUpstreamSnapshots") == "true"

// This is the version of the upstream instrumentation BOM
-val otelVersion = "1.32.0-adot1"
+val otelVersion = "1.32.0-adot-lambda1"
val otelSnapshotVersion = "1.33.0"
val otelAlphaVersion = if (!TEST_SNAPSHOTS) "$otelVersion-alpha" else "$otelSnapshotVersion-alpha-SNAPSHOT"
val otelJavaAgentVersion = if (!TEST_SNAPSHOTS) otelVersion else "$otelSnapshotVersion-SNAPSHOT"
Loading
Loading