Microsoft Azure App Services Extension
Rapport de recherche Datadog : Bilan sur l'adoption de l'informatique sans serveur Rapport : Bilan sur l'adoption de l'informatique sans serveur

Microsoft Azure App Services Extension

Cette page n'est pas encore disponible en français, sa traduction est en cours.
Si vous avez des questions ou des retours sur notre projet de traduction actuel, n'hésitez pas à nous contacter.
This service is in public beta. If you have any feedback, contact Datadog support. During the beta period, the use of this extension is not metered for billing purposes.


Microsoft Azure App Services is a group of serverless resources that enable you to build and host web apps, mobile back ends, event-driven functions, and RESTful APIs without managing infrastructure. It can host workloads of all sizes and offers auto-scaling and high availability options.

Datadog provides monitoring capabilities for all Azure App Services resource types:

The Datadog extension for Azure App Services provides additional monitoring capabilities for Azure Web Apps. This support includes:

  • Full distributed APM tracing using automatic instrumentation.
  • Support for manual APM instrumentation to customize spans.
  • Trace_ID injection into application logs.



The Datadog .NET APM extension supports the following .NET runtimes in both x64 and x86 architectures when running on Windows instances (AAS does not yet support extensions on Linux). For more details about automatically instrumented libraries, see the Tracer documentation.

  • .NET Framework 4.7 and later
  • .NET Core 2.1
  • .NET Core 2.2 (Microsoft support ended 2019-12-23)
  • .NET Core 3.0 (Microsoft support ended 2020-03-03)
  • .NET Core 3.1


  1. Open the Azure Portal and navigate to the dashboard for the Azure App Services instance you wish to instrument with Datadog.
  2. Go to the Application settings tab of the Configuration page.
  3. Add your Datadog API key as an application setting called DD_API_KEY and a value of your Datadog API Key.
  4. If you use the EU Datadog site ( domain), add an application setting DD_SITE with as the value. By default, the extension submits data to the US Datadog site (the domain). So if you use the US Datadog site, there is no additional application setting required.
  5. Go to the extensions page and click Add.
  6. Select the Datadog APM extension.
  7. Accept the legal terms, click OK, and wait for the installation to complete.
  8. Restart the main application: click Stop, wait for a full stop, then click Start.

Logging from Azure Web Apps

Logs for Azure Web Apps can be submitted to Datadog with Eventhub using the process described in the Azure Integration documentation. Note: The Eventhub must be located in the same region as your web application.

Once the Eventhub and forwarder function are configured, create a diagnostic setting for your web application. Select the logs you want to send to Datadog:

Once you establish the logging pipeline for your application, Trace ID injection allows you to connect logs and traces in Datadog. To enable this with the extension, add an application setting DD_LOGS_INJECTION:true.

Note: Trace ID injection occurs in the application, so application logs include the trace ID. Other categories of diagnostic logs available from Azure, like HTTP logs and audit logs, do not include the trace ID.


5XX errors

If your app begins throwing 5XX errors immediately after installation, first try to reinstall with the application in a full stop. To do this:

  1. Stop the application.
  2. Remove the Datadog extension.
  3. Reinstall the Datadog extension.
  4. Restart your application.

A clean install to a stopped app typically solves the problem. However, if you’re still getting 5XX errors, it may be related to something like an enabled debug setting, which can slow down the startup time of your application, and can result in a 500 error. You can also try:

  • Adjusting your logging and application settings
  • Move your application to a more powerful App Service Plan

Missing traces

If you’re missing traces or not receiving them at all, make sure you have not manually adjusted any port settings. The Tracer Agent, in the extension, communicates with your application to identify the correct port to use for external traffic. Manual port settings can interfere with this process resulting in missed traces.

Still need help? Contact Datadog support.

Further Reading

Documentation, liens et articles supplémentaires utiles: