Skip to content

Commit

Permalink
Annotate the fn span if it's the first time (#1331)
Browse files Browse the repository at this point in the history
Co-authored-by: Darwin D Wu <darwin67@users.noreply.github.com>
  • Loading branch information
darwin67 and darwin67 committed May 9, 2024
1 parent 5542241 commit 4f34586
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pkg/execution/executor/executor.go
Original file line number Diff line number Diff line change
Expand Up @@ -733,6 +733,7 @@ func (e *executor) Execute(ctx context.Context, id state.Identifier, item queue.
// annotate the step as the first step of the function run.
// this way the delay associated with this run is directly correlated to the delay of the
// function run itself.
fnSpan.SetAttributes(attribute.Bool(consts.OtelSysStepFirst, true))
span.SetAttributes(attribute.Bool(consts.OtelSysStepFirst, true))

// Set the start time and spanID in metadata for subsequent runs
Expand Down

0 comments on commit 4f34586

Please sign in to comment.