From 5dfc056382d5368c04133ad4869a4289c7a8ac21 Mon Sep 17 00:00:00 2001 From: Munir Abdinur Date: Mon, 6 Jan 2025 18:17:05 -0500 Subject: [PATCH] update docs --- docs/basic_usage.rst | 32 ++++++-------------------------- 1 file changed, 6 insertions(+), 26 deletions(-) diff --git a/docs/basic_usage.rst b/docs/basic_usage.rst index 4e438e154bb..c910108a73c 100644 --- a/docs/basic_usage.rst +++ b/docs/basic_usage.rst @@ -3,39 +3,19 @@ Basic Usage =========== -Tracing -~~~~~~~ +Automatic Instrumentation +~~~~~~~~~~~~~~~~~~~~~~~~~ ``ddtrace.auto`` ---------------- -To set up instrumentation within your application, call :ref:`import ddtrace.auto` as early as possible +To enable full ddtrace support (library instrumentations, profiling, application security monitoring, dynamic instrumentation, etc.) call :ref:`import ddtrace.auto` as early as possible in your application. This will only work if your application is not running under ``ddtrace-run``. -``patch_all`` -------------- - -For fine-grained control over instrumentation setup, use ``patch_all`` as early as possible -in the application:: - - from ddtrace import patch_all - patch_all() - -To toggle instrumentation for a particular module:: - - from ddtrace import patch_all - patch_all(redis=False, cassandra=False) - -By default all supported libraries will be instrumented when ``patch_all`` is -used. - -**Note:** To ensure that the supported libraries are instrumented properly in -the application, they must be patched *prior* to being imported. So make sure -to call ``patch_all`` *before* importing libraries that are to be instrumented. - -More information about ``patch_all`` is available in the :py:func:`patch_all` API -documentation. +Note: Some Datadog products and instrumentations are disabled by default. Products and instrumentations can be enabled/disable via environment variables, see :ref:`configurations ` page for more details. +Tracing +~~~~~~~ Manual Instrumentation ----------------------