question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Azure Functions does not support DiagnosticListener callbacks when using System.Diagnostics.DiagnosticSource (> 4.7.0)

See original GitHub issue

DiagnosticListener callbacks are not called in Function apps when using System.Diagnostics.DiagnoticSource (> 4.7.0)

Investigative information

Tried this locally

Repro steps

Expected behavior

Response should be:

[
    "System.Net.Http.HttpRequestOut.Start",
    "System.Net.Http.Request",
    "System.Net.Http.HttpRequestOut.Stop",
    "System.Net.Http.Response"
]

This is a list of events that are logged by HttpClient when making an outbound Http request

Actual behavior

Response is empty

Known workarounds

Revert the System.Diagnostics.DiagnosticSource package version to 4.7.0

Related information

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
RohitRanjanMScommented, Jan 21, 2022

@utpilla this is working in V4, we can close this issue. @brettsam @fabiocav FYI

1reaction
fabiocavcommented, Sep 22, 2021

We need to track the unification change in 4.0.

Tagging @brettsam for validation in v4

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why can't I subscribe to HttpHandlerDiagnosticListener in ...
HttpHandlerDiagnosticListener has no public constructor. To use this, the application just needs to call DiagnosticListener.
Read more >
Microsoft Q&A
Azure functions project getting PlatformNotSupportedException after updating System.Diagnostics.PerformanceCounter from 4.7.0 to 5.0.0 (C#lib, ...
Read more >
System.Diagnostics.Activity Update and Distributed Tracing in ...
I heard that the Activity class has a big update at 4.6.0 Currently latest is 4.7.0 I wrote some code to enable distributed...
Read more >
Autofac Documentation
This TodayWriter is where it all comes together. // Notice it takes a constructor parameter of type. // IOutput - that lets the...
Read more >
Untitled
Diagnosticlistener httpclient This walkthrough shows how to create a DiagnosticSource event and instrument code with System.Diagnostics.DiagnosticSource.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found