Using Application Insights
To me, it is critical to monitor applications and detect failures before receiving a phone call from my clients. With Azure being a closed ecosystem, you will struggle to support your applications without logging in your application that can tell you what is going on. I like to leverage Azure Application Insights and NLog to help with logging in my applications; then, I can build my monitoring from there. Application Insights can be installed with most resources and gives you some insights for free, almost like the event log on a traditional server.
Application Insights provides telemetry about your app, and when things don't get right, it is good to understand that there are two main types of telemetry—raw and aggregated instances. Aggregated data includes the counts of events per unit of time or averages. Now, it is good to understand the following categories of collected data:
- Dependencies
- App Requests
- Exceptions
- Page Views
- Performance counters
- Log Traces
- Custom Events...