Skip to content
This repository was archived by the owner on Jan 11, 2023. It is now read-only.

Commit 468af1f

Browse files
authored
Updated manual context prop documentation
1 parent 8a237c4 commit 468af1f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -309,9 +309,13 @@ exports.handler = signalFxLambda.asyncWrapper(async (event, context) => {
309309
tracing.inject(contextCarrier);
310310
// contextCarrier is now extended with "X-B3-*" fields, which should be extracted on the receiving end
311311
// no fields will be added unless there's an active span at the time when inject() is called
312+
313+
// inject contextCarrier such that it can be accessed as `event.headers` from within the invoked lambda.
312314
});
313315
```
314316
317+
`contextCarrier` must be injected into the headers or payload of your outgoing request. Context propagation will work correctly as long as the context you injected can be accessed as `event.headers` from within the invoked Lambda.
318+
315319
### Asynchronous Metrics and Events Delivery
316320
317321
Although the following `signalFxLambda.helper.send*` methods all return promises that resolve when send operation completes it is recommended to ignore those promises as the wrapper is going to wait for their completion internally.

0 commit comments

Comments
 (0)