Azure Functions Logging
Overview
The following categories of Logs are available to export to Storage Account or EventHub.
- Function App logs
- Function Authentication logs (beta)
Although, the application logs could be sent directly in the Application Level using a OpenTelemetry Log Appender, this might not an option for managed services.
Prerequisites
Setup
- Navigate to your Azure Function in the Azure portal
- Search for "Diagnostic settings" in the left navigation menu
- Click on "Add Diagnostic Setting"
- Select the desired log categories to export:
- Function App logs
- Configure the destination details as "Stream to an Event Hub" and select the Event Hub namespace and Event Hub name created during the EventHub Setup
- Save the diagnostic settings
That's it! You have successfully set up logging for your Azure Function.
Was this page helpful?
On this page