Azure Functions monitoring data reference

This reference applies to the use of Azure Monitor for monitoring function apps hosted in Azure Functions. See Monitoring function app with Azure Monitor for details on using Azure Monitor to collect and analyze monitoring data from your function apps.

See Monitor Azure Functions for details on the data you can collect for Azure Functions and how to use it.

See Monitor executions in Azure Functions for details on using Application Insights to collect and analyze log data from individual functions in your function app.

Azure Functions specific metrics

There are two metrics that are of specific interest to function apps:

Hosting plans that allow your apps to scale dynamically support extra Functions-specific metrics:

These metrics are used to estimate the costs associated with on demand and always ready meters used for billing in a [Flex Consumption plan]:

Metric Description Meter calculation
OnDemandFunctionExecutionCount Total number of function executions in on demand instances. OnDemandFunctionExecutionCount / 10 is the On Demand Total Executions meter, for which the unit of measurement is in tens.
AlwaysReadyFunctionExecutionCount Total number of function executions in always ready instances. AlwaysReadyFunctionExecutionCount / 10 is the Always Ready Total Executions meter, for which the unit of measurement is in tens.
OnDemandFunctionExecutionUnits Total MB-milliseconds from on demand instances while actively executing functions. OnDemandFunctionExecutionUnits / 1,024,000 is the On Demand Execution Time meter, in GB-seconds.
AlwaysReadyFunctionExecutionUnits Total MB-milliseconds from always ready instances while actively executing functions. AlwaysReadyFunctionExecutionUnits / 1,024,000 is the Always Ready Execution Time meter, in GB-seconds.
AlwaysReadyUnits The total MB-milliseconds of always ready instances assigned to the app, whether or not functions are actively executing. AlwaysReadyUnits / 1,024,000 is the Always Ready Baseline meter, in GB-seconds.

In this table, all execution units are calculated by multipling the fixed instance memory size, such as 512 MB or 2,048 MB, by total execution times, in milliseconds.

Supported metrics for Microsoft.Web/sites

The following table lists the metrics available for the Microsoft.Web/sites resource type. Most of these metrics apply to both function app and web apps, which both run on App Service.

Note

These metrics aren't available when your function app runs on Linux in a Consumption plan.

Table headings

  • Metric - The metric display name as it appears in the Azure portal.
  • Name in Rest API - Metric name as referred to in the REST API.
  • Unit - Unit of measure.
  • Aggregation - The default aggregation type. Valid values: Average, Minimum, Maximum, Total, Count.
  • Dimensions - Dimensions available for the metric.
  • Time Grains - Intervals at which the metric is sampled. For example, PT1M indicates that the metric is sampled every minute, PT30M every 30 minutes, PT1H every hour, and so on.
  • DS Export- Whether the metric is exportable to Azure Monitor Logs via Diagnostic Settings. For information on exporting metrics, see Create diagnostic settings in Azure Monitor.

Metric dimensions

For information about what metric dimensions are, see Multi-dimensional metrics.

Azure Functions doesn't have any metrics that contain dimensions.

Resource logs

This section lists the types of resource logs you can collect for this service. The section pulls from the list of all resource logs category types supported in Azure Monitor.

Supported resource logs for Microsoft.Web/sites

The log specific to Azure Functions is FunctionAppLogs.

For more information, see the App Service monitoring data reference.

Azure Monitor Logs tables

This section refers to all of the Azure Monitor Logs tables relevant to this service, which are available for query by Log Analytics using Kusto queries.

This service uses the listed tables to store resource log data. The following columns are relevant.

App Services

Microsoft.Web/sites

Activity log

The linked table lists the operations that may be recorded in the activity log for this service. This is a subset of all the possible resource provider operations in the activity log.

For more information on the schema of activity log entries, see Activity Log schema.

The following table lists operations related to Azure Functions that might be created in the activity log.

Operation Description
Microsoft.web/sites/functions/listkeys/action Return the keys for the function.
Microsoft.Web/sites/host/listkeys/action Return the host keys for the function app.
Microsoft.Web/sites/host/sync/action Sync triggers operation.
Microsoft.Web/sites/start/action Function app started.
Microsoft.Web/sites/stop/action Function app stopped.
Microsoft.Web/sites/write Change a function app setting, such as runtime version or enable remote debugging.

You may also find logged operations that relate to the underlying App Service behaviors. For a more complete list, see Microsoft.Web resource provider operations.