This PR merges the two functions by moving the code of shouldUpdateStepForTracesMerging() into injectContextForLambdaFunctions().
Why?
We will soon have different instrumentation strategies depending on the existing state of Lambda definition, so shouldUpdateStepForTracesMerging() which has a boolean return value will no longer work.
What
Currently the
injectContextForLambdaFunctions()
function roughly looks like this:It calls
shouldUpdateStepForTracesMerging()
.This PR merges the two functions by moving the code of
shouldUpdateStepForTracesMerging()
intoinjectContextForLambdaFunctions()
.Why?
We will soon have different instrumentation strategies depending on the existing state of Lambda definition, so
shouldUpdateStepForTracesMerging()
which has a boolean return value will no longer work.Design doc: Fixing Step Function Instrumentation A short description of what changes this PR introduces and why.
Testing
Passed the touched automated tests
Review checklist