Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Azure Application Insights is a monitoring service that captures telemetry such as request details, performance counters, logs, and exceptions. Integrating it with Data API builder (DAB) helps you diagnose issues and monitor runtime behavior in production.
Warning Application Insights isn't supported when DAB is hosted using Azure App Service web apps.
Configuration
To configure Application Insights in your DAB config:
CLI example
dab add-telemetry \
--app-insights-enabled true \
--app-insights-conn-string "@env('app-insights-connection-string')"
JSON example
"runtime": {
...
"telemetry": {
"application-insights": {
"enabled": true,
"connection-string": "@env('app-insights-connection-string')"
}
}
...
}
This assumes app-insights-connection-string
is set as an environment variable. You can use an .env
file to define it.
What gets captured
Type | Description |
---|---|
Request telemetry | URL, status code, response time |
Trace telemetry | Console logs from DAB |
Exception telemetry | Errors and stack traces |
Performance counters | CPU, memory, network metrics |
View in Azure
- Go to your Application Insights resource in the Azure portal: https://portal.azure.com
- Review logs using this query:
traces
| order by timestamp
LogLevel mapping:
LogLevel | Severity | Value |
---|---|---|
Trace | Verbose | 0 |
Debug | Verbose | 0 |
Information | Information | 1 |
Warning | Warning | 2 |
Error | Error | 3 |
Critical | Critical | 4 |
- Check Live Metrics
- Run this query for requests:
requests
| order by timestamp
- Run this query for exceptions:
exceptions
| order by timestamp