Skip to content

feat: identify OS-only runtimes in SDK user agents - #874

Open
M-Elsaeed wants to merge 1 commit into
aws:mainfrom
M-Elsaeed:p393687910-execution-env
Open

M-Elsaeed wants to merge 1 commit into
aws:mainfrom
M-Elsaeed:p393687910-execution-env

Conversation

@M-Elsaeed

Copy link
Copy Markdown

Summary

  • default AWS_EXECUTION_ENV to AWS_Lambda_provided_custom in the Lambda layer bootstrap while preserving an existing value
  • document the equivalent Dockerfile setting for OS-only container images, where multi-stage COPY --from cannot inherit environment metadata
  • execute the real layer wrapper in an integration regression test covering both default and preserve behavior

This allows AWS SDK user agents to identify requests from OS-only Lambda runtimes, including alternative JavaScript runtimes such as Bun.

Testing

  • cargo test --test integ_tests test_layer_bootstrap_sets_execution_environment
  • cargo test --lib --bins --tests -- --test-threads=1 (99 passed; 4 deployment E2E tests ignored)
  • cargo fmt --all -- --check
  • bash -n layer/bootstrap
  • cargo clippy --all-targets (passes with three pre-existing warnings in untouched files)
  • cargo build

@M-Elsaeed
M-Elsaeed requested a review from a team as a code owner October 8, 2026 14:10
@bnusunny

bnusunny commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

@M-Elsaeed Thanks for the PR. Can you give me more background why we want to do this in LWA instead of in the OS-only Lambda runtimes?

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants