Crossposting original bug from https://github.com/Azure/azure-service-bus-dotnet/issues/588
Actual Behavior
Ensure AppInisight is configured and dependency tracking is enabled.
Construct a SubscriptionClient for a topic with sessions enabled.
Call RegisterSessionHandler on the client.
(When nothing is published on the topic): every hour 7000 "AcceptMessageSession" dependencies with "Dependency call status" as False are logged in AppInsight.
Expected Behavior
When nothing is published there should not be anything logged in AppInsight. Or at least it should not log a failed dependency.
Versions
OS platform and version: Windows 10 Pro, 1803
.NET Version: .NET 4.6
NuGet package version or commit ID:
Comments:
Using RegisterMessageHandler instead of RegisterSessionHandler also causes a dependency "Receive" to be logged every 1 minute, but this has a status of True, which is much less noisy in AppInsight.
We're facing the same issue for a while now, and it's generating roughly 7k (!) false exceptions in application insights PER hour. This not only makes it difficult to find relevant exceptions in AI, it also consumes a lot of storage space compared to our other logs.
Thanks for bringing this issue to our attention. I have routed to the appropriate team for follow-up.
@Mortana89, thank you for bringing this issue to our attention...again. An engineer from our team should be looking at this issue soon.
Thanks for fixing this! When will this be available in a new package @nemakam ?
I don't have an ETA right now, but will try to get it out in a week or two. There are a couple of more things that needs to get in for the next release.
Hi @nemakam, do you have an update when this is available?
Just published the new version. https://www.nuget.org/packages/Microsoft.Azure.ServiceBus/4.0.0
@nemakam i have updated to the latest version, but still get these failures in AppInsights.
This is from an aspnetcore 2.2 app service running in Azure App Services.
Same here...
Interesting. What's the exception that you see? Timeout exception?
don't see it as an application exception, but it shows up as a dependency failure on the service bus topic with an "undefined" response code.


@lmolkova, would you please help us fix this issue? Thanks.
This looks like call to ServiceBus in an attempt to accept message session but it ends with timeout (60s) and does not do much.
The only way to mitigate it, for now, is to implement and configure custom telemetry processor that would filter such calls out.
I created issue in AppInsights repo to track the fix https://github.com/microsoft/ApplicationInsights-dotnet-server/issues/1281
This costs us a lot of AI data. When can we expect a fix for this?
This needs to go through the triage and planning process before we can commit to certain date. For now, please try workaround with telemetry processor
@lmolkova, in the interest of setting the right expectations, would you please share an approximate month in the future (even beyond your current planning period if that is the right answer) when a permanent solution for this issue would be provided.
I can do this after we triage and plan this, but next stable version will happen in ~3 months and this is the earliest when fix could be delivered. Beta versions might get fix earlier. Please follow the AppInsights issue microsoft/ApplicationInsights-dotnet-server#1281 - we'll set milestone there when we'll do the planning.
Closing this issue here. Kindly track this issue through - https://github.com/microsoft/ApplicationInsights-dotnet/issues/1348
Most helpful comment
don't see it as an application exception, but it shows up as a dependency failure on the service bus topic with an "undefined" response code.
