Skip to content

make sidecar re-instrument idempotent and enable APM on container-app#2370

Merged
ava-silver merged 1 commit into
masterfrom
ava.silver/chore/sidecar-reinstrument-idempotency
Jun 22, 2026
Merged

make sidecar re-instrument idempotent and enable APM on container-app#2370
ava-silver merged 1 commit into
masterfrom
ava.silver/chore/sidecar-reinstrument-idempotency

Conversation

@ava-silver

@ava-silver ava-silver commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

What and why?

Re-running instrument on a serverless-init sidecar target (Azure Container App) must be a true no-op. Previously a re-instrument could drop provider-populated sidecar fields (e.g. resources) and re-append the shared volume mount, producing config drift. This makes the sidecar merge idempotent and enables APM on the Container App sidecar.

Split out from the Container App e2e PR (#2364) so the production behavior change is reviewed on its own. Stacked on #2333.

How?

  • packages/base/src/helpers/serverless/common.ts: when a sidecar container already exists, merge the new config onto it -- preserving existing resources and env vars, and deduping the shared volume mount via a new ensureSharedVolumeMount helper -- instead of replacing it wholesale.
  • packages/plugin-container-app/src/common.ts: set DD_APM_ENABLED=true so the sidecar enables APM.
  • Updates the affected unit tests and the instrument snapshot.

Test plan

Review checklist

  • Feature or bugfix MUST have appropriate tests (unit, integration)

ava-silver commented Jun 17, 2026

Copy link
Copy Markdown
Contributor Author

@ava-silver
ava-silver marked this pull request as ready for review June 17, 2026 18:24
@ava-silver
ava-silver requested review from a team as code owners June 17, 2026 18:24
@ava-silver
ava-silver requested a review from avangelillo June 17, 2026 18:24
@ava-silver ava-silver added the serverless Related to [aas, cloud-run, lambda, stepfunctions] label Jun 17, 2026
@ava-silver ava-silver added the chores Related to the CI or developer experience label Jun 17, 2026 — with Graphite App
@ava-silver
ava-silver force-pushed the ava.silver/chore/sidecar-reinstrument-idempotency branch from bf73bea to cbb9f14 Compare June 17, 2026 20:37
@ava-silver
ava-silver force-pushed the tal.usvyatsky/datadog-ci-lambda-e2e-tests branch 2 times, most recently from 61bbd3b to b097b38 Compare June 17, 2026 20:45
@ava-silver
ava-silver force-pushed the ava.silver/chore/sidecar-reinstrument-idempotency branch from cbb9f14 to f151d5f Compare June 17, 2026 20:45
@ava-silver
ava-silver force-pushed the ava.silver/chore/sidecar-reinstrument-idempotency branch from f151d5f to 1383e68 Compare June 18, 2026 22:33
@ava-silver
ava-silver force-pushed the tal.usvyatsky/datadog-ci-lambda-e2e-tests branch from b097b38 to 957856e Compare June 18, 2026 22:33
@ava-silver
ava-silver force-pushed the ava.silver/chore/sidecar-reinstrument-idempotency branch from 1383e68 to 56385ad Compare June 22, 2026 14:37
@datadog-datadog-prod-us1-2

datadog-datadog-prod-us1-2 Bot commented Jun 22, 2026

Copy link
Copy Markdown

Tests

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: e3f84a2 | Docs | Datadog PR Page | Give us feedback!

@ava-silver
ava-silver force-pushed the ava.silver/chore/sidecar-reinstrument-idempotency branch from 56385ad to 624a228 Compare June 22, 2026 14:50
@ava-silver
ava-silver force-pushed the tal.usvyatsky/datadog-ci-lambda-e2e-tests branch from 34e1df8 to 9ed1b16 Compare June 22, 2026 15:26
@ava-silver
ava-silver force-pushed the ava.silver/chore/sidecar-reinstrument-idempotency branch from 624a228 to 43b9424 Compare June 22, 2026 15:26
@ava-silver
ava-silver changed the base branch from tal.usvyatsky/datadog-ci-lambda-e2e-tests to graphite-base/2370 June 22, 2026 16:27
@ava-silver
ava-silver force-pushed the ava.silver/chore/sidecar-reinstrument-idempotency branch from 43b9424 to ed8a368 Compare June 22, 2026 16:27
@ava-silver
ava-silver force-pushed the graphite-base/2370 branch from 9ed1b16 to ba7805a Compare June 22, 2026 16:27
@graphite-app
graphite-app Bot changed the base branch from graphite-base/2370 to master June 22, 2026 16:28
@ava-silver
ava-silver force-pushed the ava.silver/chore/sidecar-reinstrument-idempotency branch from ed8a368 to e3f84a2 Compare June 22, 2026 16:28

ava-silver commented Jun 22, 2026

Copy link
Copy Markdown
Contributor Author

Merge activity

  • Jun 22, 5:01 PM UTC: A user started a stack merge that includes this pull request via Graphite.
  • Jun 22, 5:02 PM UTC: @ava-silver merged this pull request with Graphite.

@ava-silver
ava-silver merged commit 8bd7b27 into master Jun 22, 2026
34 checks passed
@ava-silver
ava-silver deleted the ava.silver/chore/sidecar-reinstrument-idempotency branch June 22, 2026 17:02
@ava-silver ava-silver mentioned this pull request Jun 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

chores Related to the CI or developer experience serverless Related to [aas, cloud-run, lambda, stepfunctions]

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants