1.3 Configure diagnostics, monitoring, and analytics
Retrieve diagnostics data; view streaming logs; configure endpoint monitoring, configure alerts; configure diagnostics; use remote debugging; monitor Web App resources
1.3.1 Retrieve diagnostics data
Enable diagnostics logging for web apps in Azure App Service: https://docs.microsoft.com/en-us/azure/app-service-web/web-sites-enable-diagnostic-log
1.3.2 View streaming logs
Streming logs lar deg se i "real time" hva applikasjonen din driver med, hvis den har mulighet for å logge til konsoll.
Du kan akksessere streamin-logs gjennom Azure Web Portal under Log Streaming eller gjennom Azure Developer Consoll ( Vistual Studio).
https://docs.microsoft.com/en-us/azure/app-service-web/web-sites-streaming-logs-and-console
1.3.3 Configure endpoint monitoring
Web Application Endpoint Monitoring has been removed from Azure since October 31, 2016.
The new, replacement functionality isApplication Insight Availability Tests
About Application Insight: https://azure.microsoft.com/en-gb/services/application-insights/
1.3.4 Configure alerts
Azure Metric Alerts kan settes opp slik vi kan få beskjed om applikasjonen vår oppfører seg på en bestemt måte, basert på regler vi har satt opp i forkant.
Create metric alerts in Azure Monitor for Azure services: https://docs.microsoft.com/en-us/azure/monitoring-and-diagnostics/insights-alerts-portal
1.3.5 Configure diagnostics
Å konfigurere Diagnostics gjøres under Configure Diagnostics i Azure Web Portal.Her har man muligheten til å konfigurere følgende:
- Application Logging
- Om man i det hele tatt skal logge
- Level
- Hvor mye man skal logge
- Error
- Warning
- Information
- Verbose
- Hvor mye man skal logge
- Application Logging (Blob)
- Blob er en spesiell lagringsplass/type i Azure. Spesifisere om man vil skrive loggen til Blob Storage
- Web Server Logging
- Om man vil ha logging fra Web Serveren (IIS). Her ser man aktivitet som individuelle GET-requests o.l
Detailed Error Messages
- Om man vil ha en stacktrace av error. (!usikker på denne, har ikke testet)
- Failed request Tracing
1.3.6 Use remote debugging
To configure and remote debug your Microsoft Azure App Service Web App, you will need to perform the following:
- Have a Web App deployed to the Azure platform
- Attach the remote debugger to the Web App
- Confirm the remote debugger is attached to the W3WP process
- Set the break points
- Execute the process which is rendering the exception, performing slow or in an unexpected manner
- Debugging other technologies
Remote debug your Azure App Service Web App: https://blogs.msdn.microsoft.com/benjaminperkins/2016/09/22/remote-debug-your-azure-app-service-web-app/
1.3.7 Monitor Web App resources
How to: Monitor Apps in Azure App Service: https://docs.microsoft.com/en-us/azure/app-service-web/web-sites-monitor