Skip to content

Commit

Permalink
Capture the azure function delegate invoke exception on Transaction (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Mpdreamz authored Feb 23, 2023
1 parent c5c53f3 commit 4ce08b5
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Elastic.Apm.Azure.Functions/ApmMiddleware.cs
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ await Agent.Tracer.CaptureTransaction(data.Name, ApiConstants.TypeRequest, async
catch (Exception ex)
{
success = false;
t.CaptureException(ex);
Logger.Log(LogLevel.Error, $"Exception was thrown during '{nameof(Invoke)}'", ex, null);
throw;
}
Expand Down

0 comments on commit 4ce08b5

Please sign in to comment.