aws / aws-xray-sdk-node

The official AWS X-Ray SDK for Node.js.
Apache License 2.0
266 stars 155 forks source link

[Lambda] Replace Facade with No-Op if trace header is missing data #651

Closed majanjua-amzn closed 2 months ago

majanjua-amzn commented 2 months ago

To support Root Lambda PassThrough, we want to have a no-op segment when PassThrough mode is enabled to allow for SDK to have its functionalities disabled for the given segment. The following tests were done using two lambda functions, A and B, where A calls B.

Lambda A PassThrough calling Prod Lambda B Active:

Lambda A Active calling Prod Lambda B Active:

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

codecov-commenter commented 2 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 82.80%. Comparing base (73e1fca) to head (2c415e1).

:exclamation: Current head 2c415e1 differs from pull request most recent head 1d6d314

Please upload reports for the commit 1d6d314 to get more accurate results.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #651 +/- ## ========================================== - Coverage 83.49% 82.80% -0.70% ========================================== Files 37 37 Lines 1806 1855 +49 ========================================== + Hits 1508 1536 +28 - Misses 298 319 +21 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.