Azure / azure-functions-host

The host/runtime that powers Azure Functions
https://functions.azure.com
MIT License
1.94k stars 441 forks source link

Improved Telemetry Processing in Azure Functions #9961

Open RohitRanjanMS opened 7 months ago

RohitRanjanMS commented 7 months ago

To address the challenges and gaps identified with the current logging and telemetry capture mechanisms in Azure Functions, the following proposal outlines a new approach aimed at enhancing privacy compliance, improving customer experience, and ensuring richer telemetry capture.

Challenges and Gaps

Azure Functions, allows users to run event-triggered code without the need to explicitly provision or manage infrastructure. While Azure Functions offers robust logging and monitoring capabilities, there are identified challenges in its current default implementation, particularly concerning the processing of customer-generated telemetry.

Although customers can set up Application Insights directly on the worker to bypass the issues linked to the standard logging method, they frequently, perhaps unwittingly, opt for the default behavior.

In the default mode, the host process in Azure Functions is responsible for capturing and processing all logs, including those generated by the worker process and customer code. These logs are then sent to configured sinks such as Application Insights, Azure Monitor, and others. This architecture, while functional, presents several challenges:

image

Goal

To overcome these challenges, a new default logging and telemetry mechanism is proposed. This mechanism will:

Benefits

jviau commented 7 months ago

@RohitRanjanMS - how does this issue differ from #9273? Can we consolidate down to one issue? If they are indeed separate, we should open a telemetry epic issue and add a task list for all the individual telemetry issues