Collaboration Not Competition

Using Application Insights to assess general health of Azure Functions

July 15, 2019

To enable monitoring of an Azure Function follow this guide.

Now that monitoring is setup we are able to create queries that allow for some general health monitoring of our Azure Functions.

To get a count of each type of http result code for the last 30 days:

requests | where timestamp > ago(30d)
| summarize count() by resultCode

To get the average duration of each function for the last 7 days:

Average duration of operations.txt

requests | where timestamp > ago(7d)
| summarize count(), min(duration) , max(duration), avg(duration) by operation_Name

To get the average duration per day of a specific function:

requests | where name == "OperationName" |
where timestamp > ago(30d) and operation_Name != ""
| summarize avg(duration) by operation_Name, bin(timestamp, 1d)