question

Julia-1392 avatar image
0 Votes"
Julia-1392 asked Julia-1392 commented

Cannot see exceptions in Application Insigths

Hello

I have an ASP.NET MVC 5 application and I have added Application Insights to it. I simply did it in Visual Studio in the meny "Configure Application Insights...". It works and I can see data in Application Insights. I see all requests, both 200 and failing ones.

But, I cannot see the Exception part. If I click on a 500 request, there is no information on what went wrong, and I cannot see the Exception information or the Stack Trace.

What can I do to be see the Exception and the Stack Trace in Application Insights.

Thanks!
Julia

dotnet-aspnet-mvc
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

YijingSun-MSFT avatar image
0 Votes"
YijingSun-MSFT answered Julia-1392 commented

Hi @Julia-1392 ,
If you have no data for Application Insights, I'm guessing that the problems are these:
1. It's probably a firewall issue.
2. IIS Server might be missing some prerequisites, like .NET Extensibility 4.5 or ASP.NET 4.5.

More details,you could refer to below article:
https://docs.microsoft.com/en-us/azure/azure-monitor/app/asp-net-troubleshoot-no-data

Best regards,
Yijing Sun


If the answer is helpful, please click "Accept Answer" and upvote it.

Note: Please follow the steps in our  documentation  to enable e-mail notifications if you want to receive the related email notification for this thread.

· 3
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hello

I can see data. I see all "Server Request" and "Failed Requests". But when I drill down on a Failed Request (500) I see no Stack Trace or Exception information. For other applications we have, there are more information available for Failed Requests (500).

Thanks

0 Votes 0 ·

Hi @Julia-1392 ,
In app insights query window, write a query to display exceptions and project the property called "details". That contains the stack trace information.

  exceptions
 | where timestamp > ago(30d)
 | order by timestamp asc
 | project timestamp, message = iff(message != '', message, iff(innermostMessage != '', innermostMessage, customDimensions.['prop__{OriginalFormat}'])), details

Best regards,
Yijing Sun

1 Vote 1 ·

Thanks, this is what I was looking for!

0 Votes 0 ·