User Tools

Site Tools


devops:monitoring:datadog:ddtrace

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
devops:monitoring:datadog:ddtrace [2025/02/14 14:08] 85.219.17.206devops:monitoring:datadog:ddtrace [2025/02/14 14:11] (current) 85.219.17.206
Line 25: Line 25:
     pass     pass
 </code> </code>
 +
 +Alternatively, you can use ddtrace to automatically instrument various libraries, such as Flask, Django, Celery, and more, with minimal configuration.
 +
 +<code:python>
 +from ddtrace import patch_all
 +patch_all()  # This will automatically trace supported libraries
 +</code>
 +
 +==== Configuration ====
 +
 +The Datadog tracer can be configured with several options, such as setting the agent host, enabling/disabling certain integrations, and adjusting sampling rates.
 +
 +Here are some common configuration options:
 +
 +      * Datadog Agent Host:
 +  *     Set the Datadog Agent host to which traces should be sent.
 +<code:python>
 +from ddtrace import tracer
 +tracer.configure(hostname='localhost', port=8126)
 +</code>
 +
 +==== Supported Libraries ====
 +
 +ddtrace supports a wide range of libraries and frameworks out of the box. Some popular integrations include:
 +
 +      Flask: For tracing HTTP requests in Flask applications.
 +  *     Django: For monitoring Django-based applications.
 +  *     Celery: For tracing background tasks with Celery.
 +  *     SQLAlchemy: For tracing database queries.
 +  *     Redis: For tracing Redis interactions.
 +
 +To enable tracing for these frameworks, simply import the relevant module, and ddtrace will automatically instrument them.
  
devops/monitoring/datadog/ddtrace.1739542121.txt.gz · Last modified: 2025/02/14 14:08 by 85.219.17.206