You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/en/profiler/enabling/dotnet.md
+5-4Lines changed: 5 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -76,7 +76,7 @@ The following profiling features are available in the following minimum versions
76
76
- Allocations and Live Heap profiling are available in .NET 10. For other previous versions of .NET, the statistical distribution of allocations sampling might not be accurate, so expect larger objects to be represented more often
77
77
- Continuous Profiler is not supported for AWS Lambda.
78
78
- Continuous Profiler does not support ARM64.
79
-
79
+
80
80
<divclass="alert alert-danger">
81
81
<strong>Note:</strong> Unlike APM, Continuous Profiler is not activated by default when the APM package is installed. You must explicitly enable it for the applications you want to profile.
82
82
</div>
@@ -100,11 +100,11 @@ You can install the Datadog .NET Profiler machine-wide so that any services on t
100
100
1. With [Single Step APM Instrumentation][1], there is nothing else to install. Go to [Enabling the Profiler](#enabling-the-profiler) to see how to activate the profiler for an application.
101
101
102
102
<divclass="alert alert-danger">
103
-
<strong>Note:</strong> If APM was already manually installed, you must uninstall it by removing the following environment variables:<br />
103
+
<strong>Note:</strong> If APM was already manually installed, you must uninstall it by removing the following environment variables:<br />
104
104
- <code>CORECLR_ENABLE_PROFILING</code><br />
105
105
- <code>CORECLR_PROFILER</code><br />
106
106
- <code>CORECLR_PROFILER_PATH</code><br />
107
-
- The value that points to <code>Datadog.Linux.ApiWrapper.x64.so</code> in <code>LD_PRELOAD</code><br /><br />
107
+
- The value that points to <code>Datadog.Linux.ApiWrapper.x64.so</code> in <code>LD_PRELOAD</code><br /><br />
108
108
For example, if you are setting these environment variables in your dockerfile for a service, you should remove them to avoid conflicts with Single Step Instrumentation.
109
109
If these environment variables are still set, the corresponding previously installed version is silently used instead of the one installed with Single Step Instrumentation.
110
110
</div>
@@ -471,7 +471,7 @@ You can configure the profiler using the following environment variables. Note t
471
471
|`DD_PROFILING_HEAP_ENABLED`| Boolean | If set to `true`, enables Live Heap profiling (in Preview). Defaults to `false`. |
472
472
|`DD_PROFILING_GC_ENABLED`| Boolean | If set to `false`, disables Garbage Collection profiling used in Timeline user interface. Defaults to `true`. |
473
473
|`DD_PROFILING_HTTP_ENABLED`| Boolean | If set to `true`, enables outgoing HTTP request profiling used in Timeline user interface. Defaults to `false`. |
474
-
|`DD_PROFILING_HEAPSNAPSHOT_ENABLED`| Boolean | If set to `true`, enables the regular generation of a heap snapshot in case of memory consumption increase. This is used in the Memory Leak user interface. Defaults to `false`. |
474
+
|`DD_PROFILING_HEAPSNAPSHOT_ENABLED`| Boolean | If set to `true`, enables the regular generation of a heap snapshot in case of memory consumption increase. This is used in the [Memory Leak user interface][15]. Defaults to `false`. |
475
475
476
476
477
477
<divclass="alert alert-danger">
@@ -495,3 +495,4 @@ The [Getting Started with Profiler][4] guide takes a sample service with a perfo
| {{< ci-details title="CPU" >}}The time each function/method spent running on the CPU.{{< /ci-details >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< tooltip glossary="preview" case="title" >}} |
33
+
| {{< ci-details title="CPU" >}}The time each function/method spent running on the CPU.{{< /ci-details >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< tooltip glossary="preview" case="title" >}} |
34
34
| {{< ci-details title="Exceptions" >}}The number of exceptions raised, including those caught.{{< /ci-details >}} | {{< X >}} | Python 3.7+ |||| {{< X >}} | {{< X >}} ||
35
35
| {{< ci-details title="Allocation" >}}Number and sizes of memory allocations made by each function/method, including allocations which were subsequently freed.{{< /ci-details >}} |[JDK 11+][17]| Python 3.6+ | {{< X >}} | {{< X >}} || {{< tooltip glossary="preview" case="title" >}}<br>.NET 6+ <br>(.NET 10 recommended)| {{< X >}} | {{< tooltip glossary="preview" case="title" >}} |
36
36
| {{< ci-details title="Heap" >}}The amount of heap memory allocated that remains in use.{{< /ci-details >}} |[JDK 11+][17]| Python 3.6+ | {{< X >}} | {{< tooltip glossary="preview" case="title" >}}<br>Ruby 3.1+<br>Not yet compatible with Ruby 4 | {{< X >}} | {{< tooltip glossary="preview" case="title" >}}<br>.NET 7+ <br>(.NET 10 recommended) || {{< tooltip glossary="preview" case="title" >}} |
@@ -47,7 +47,7 @@ The following table outlines additional profiling features by language. For full
47
47
| {{< ci-details title="Trace to Profiling integration" >}}Find specific lines of code related to performance issues. <ahref="/profiler/connect_traces_and_profiles/#identify-code-hotspots-in-slow-traces">Learn more</a>{{< /ci-details >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} ||
48
48
| {{< ci-details title="Endpoint Profiling" >}}Identify endpoints that are bottlenecks or responsible for heavy resource consumption. <ahref="/profiler/connect_traces_and_profiles/#endpoint-profiling">Learn more</a>{{< /ci-details >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} ||
49
49
| {{< ci-details title="Timeline View" >}}Surface time-based patterns and work distribution over the period of a span. <ahref="/profiler/connect_traces_and_profiles/#span-execution-timeline-view">Learn more</a>{{< /ci-details >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} | {{< X >}} ||
50
-
| {{< ci-details title="Memory Leaks" >}}A guided workflow to assist in investigating memory leaks. <ahref="/profiler/guide/solve-memory-leaks/">Learn more</a>{{< /ci-details >}} | {{< X >}} || {{< X >}} ||||||
50
+
| {{< ci-details title="Memory Leaks" >}}A guided workflow to assist in investigating memory leaks. <ahref="/profiler/guide/solve-memory-leaks/">Learn more</a>{{< /ci-details >}} | {{< X >}} || {{< X >}} |||{{< X >}}|||
Copy file name to clipboardExpand all lines: content/en/profiler/guide/solve-memory-leaks.md
+13-7Lines changed: 13 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,9 +11,9 @@ further_reading:
11
11
12
12
## Overview
13
13
14
-
Profiling has several datasets to help solve memory leaks, such as the Live Heap profile type, which is [available for multiple languages][1].
14
+
Profiling has several datasets to help solve memory leaks, such as the Heap profile type, which is [available for multiple languages][1].
15
15
16
-
To help you get started, Datadog provides an end-to-end, guided walkthrough for Go or Java services:
16
+
To help you get started, Datadog provides an end-to-end, guided walkthrough for your service within the [APM service page][5]:
17
17
18
18
{{< img src="profiler/guide-memory-leak/service-page-memory-leak.png" alt="Memory Leak walkthrough entrypoint in the Service Page" style="width:100%;" >}}
19
19
@@ -25,29 +25,35 @@ The walkthrough guides you through several steps to:
25
25
1. Scope to the relevant data.
26
26
2. Recommend Datadog integrations and upgrades that assist in the investigation.
27
27
3. Explain how memory management works in your runtime.
28
-
4.Propose potential root causes through [Profile Comparisons][2].
28
+
4.Confirm potential memory leaks by inspecting retained objects through [Profile Comparisons][2].
29
29
30
30
## Requirements
31
31
32
32
To use this walkthrough, you need:
33
-
* A containerized Go or Java service with either the Datadog Kubernetes integration or the Datadog Container integration installed.
33
+
* A containerized service with either the Datadog Kubernetes integration or the Datadog Container integration installed.
34
34
*[Continuous Profiler enabled][3].
35
35
* Ensure that your profiles are tagged with `container_id`. This is necessary to link between container memory utilization metrics and profiling data.
36
+
* For Java and .NET ensure that heap profiling is enabled so that heap data is available for analysis.
37
+
* For Java: [Enabling the heap histogram metrics][6]
38
+
* For .NET: [Heap snapshot][7]
36
39
37
40
## Get started
38
41
39
42
To investigate a memory leak using the guided walkthrough:
40
43
41
44
1. Go to **[APM > Software Catalog][4]**.
42
-
1. Hover over the service you want to investigate and click **Service Page**.
43
-
1. Click the **Memory Leaks** tab.
44
-
1. Follow the guided steps to complete your investigation.
45
+
2. Hover over the service you want to investigate and click **Service Page**.
46
+
3. Click the **Memory Leaks** tab.
47
+
4. Follow the guided steps to complete your investigation.
[Learn how to use override templates.](#creating-and-using-a-jfr-template-override-file)
60
60
61
61
## Enabling the heap profiler
62
-
<divclass="aler alert-info">This feature requires at least Java 11.0.12, 15.0.4, 16.0.2, 17.0.3 or 18 and newer</div>
62
+
<divclass="alert alert-info">This feature requires at least Java 11.0.12, 15.0.4, 16.0.2, 17.0.3 or 18 and newer</div>
63
63
To enable the heap profiler, start your application with the `-Ddd.profiling.heap.enabled=true` JVM setting or the `DD_PROFILING_HEAP_ENABLED=true` environment variable.
64
64
65
65
Alternatively, you can enable the following events in your `jfp`[override template file](#creating-and-using-a-jfr-template-override-file):
[Learn how to use override templates.](#creating-and-using-a-jfr-template-override-file)
72
72
73
73
## Enabling the heap histogram metrics
74
-
<divclass="aler alert-info">This feature requires at least Java 17.0.9 or newer and does not work with ZGC</div>
74
+
<divclass="alert alert-info">This feature requires at least Java 17.0.9 or newer and does not work with ZGC</div>
75
75
76
76
To enable the heap histogram metrics, start your application with the `-Ddd.profiling.heap.histogram.enabled=true` JVM setting or the `DD_PROFILING_HEAP_HISTOGRAM_ENABLED=true` environment variable.
77
77
@@ -183,7 +183,7 @@ Below are basic troubleshooting steps for resolving those issues:
183
183
184
184
- Use dd-trace-java Version 1.47.0 or later
185
185
Starting with v1.47.0, the profiler uses PID-specific subdirectories inside the configured temp directory. This reduces clutter and potential conflicts from orphaned files when JVM processes exit unexpectedly.
186
-
186
+
187
187
- Specify a custom executable temp directory
188
188
To ensure proper operation across environments, explicitly configure a writable, executable temp directory using the following JVM option:
189
189
```
@@ -201,7 +201,7 @@ Below are basic troubleshooting steps for resolving those issues:
0 commit comments