<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>article High resource overhead issue related to the Dynatrace Log enrichment component in Troubleshooting</title>
    <link>https://community.dynatrace.com/t5/Troubleshooting/High-resource-overhead-issue-related-to-the-Dynatrace-Log/ta-p/268817</link>
    <description>&lt;H1&gt;&lt;STRONG&gt;Problem&lt;/STRONG&gt;&lt;/H1&gt;
&lt;P&gt;We can sometimes encounter high resource overhead because of the Dynatrace Object named “&lt;STRONG&gt;&lt;EM&gt;DynatraceLogEnrichmentData.combineMDCs”&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;This article will be helpful in understanding the regular working of the Log enrichment component. The technology involved is Java.&lt;/P&gt;
&lt;P&gt;Below is the example screenshot from the Memory profiling page that shows the Dynatrace Object is taking up high memory:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="logsnip2.jpg" style="width: 999px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/26318iED8765266A4A57E8/image-size/large?v=v2&amp;amp;px=999" role="button" title="logsnip2.jpg" alt="logsnip2.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;H1&gt;&amp;nbsp;&lt;/H1&gt;
&lt;H1&gt;&lt;STRONG&gt;Troubleshooting steps&lt;/STRONG&gt;&lt;/H1&gt;
&lt;P&gt;The&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;"DynatraceLogEnrichmentData.combineMDCs"&lt;/EM&gt;&lt;/STRONG&gt;&amp;nbsp;method can be safely disabled&lt;STRONG&gt;&lt;EM&gt;&amp;nbsp;&lt;/EM&gt;&lt;/STRONG&gt;by turning-off the Log Enrichment OneAgent feature for Java from the settings page. Please refer to the screenshot below to make the changes via Global settings:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="logsnip1.jpg" style="width: 999px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/26317iA2FF1FE7CEC3592B/image-size/large?v=v2&amp;amp;px=999" role="button" title="logsnip1.jpg" alt="logsnip1.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;This can also be done via process group settings on a specific application process.&lt;/P&gt;
&lt;P&gt;However, be mindful that this can be disabled only if the Application process does not use log monitoring.&lt;/P&gt;
&lt;H1&gt;&amp;nbsp;&lt;/H1&gt;
&lt;H1&gt;&lt;STRONG&gt;Working/ Expected Behavior&lt;/STRONG&gt;&lt;/H1&gt;
&lt;P&gt;The "Profiling and Optimization" page shows memory allocation. The Dynatrace objects/ methods seen in the above screenshot are freed again.&lt;/P&gt;
&lt;P&gt;This is the so-called Java object churn. It is&amp;nbsp;&lt;EM&gt;not&lt;/EM&gt;&amp;nbsp;a heap dump showing objects still in memory (memory leak).&lt;BR /&gt;It is correct that the method "&lt;STRONG&gt;&lt;EM&gt;DynatraceLogEnrichmentData.combineMDCs&lt;/EM&gt;&lt;/STRONG&gt;" is related to the log enrichment feature. The more logs are enriched, the more often it is called. However, all objects are garbage collected after the method is left.&lt;/P&gt;
&lt;P&gt;We can conclude that this behavior is expected and that there will be no issues as long as the heap memory is stable.&lt;/P&gt;
&lt;H1&gt;&amp;nbsp;&lt;/H1&gt;
&lt;H1&gt;&lt;STRONG&gt;What’s next&lt;/STRONG&gt;&lt;/H1&gt;
&lt;P&gt;If there is suspicion that the memory leak is caused by OneAgent, a full heap dump must be provided, which contains proof of leaking objects.&lt;/P&gt;
&lt;P&gt;A support case can be created in the above scenario for further troubleshooting.&lt;/P&gt;
&lt;P&gt;Note: Prediction of heap usage/ object churn can't be done. The activity of the log enrichment sensor highly depends on the configured environment settings.&lt;BR /&gt;Verbose logging via debug, trace will cause more churn than only logging warnings.&lt;BR /&gt;Also, it depends on their usage of Mapped Diagnostic Context (MDC).&lt;/P&gt;
&lt;P&gt;As the lifetime of the OneAgent objects is very short, the Garbage Collection of the JVM will actually reclaim the memory immediately. Thus, a significant heap increase should not be visible.&lt;/P&gt;</description>
    <pubDate>Mon, 17 Feb 2025 06:57:00 GMT</pubDate>
    <dc:creator>Akshay_Utekar</dc:creator>
    <dc:date>2025-02-17T06:57:00Z</dc:date>
    <item>
      <title>High resource overhead issue related to the Dynatrace Log enrichment component</title>
      <link>https://community.dynatrace.com/t5/Troubleshooting/High-resource-overhead-issue-related-to-the-Dynatrace-Log/ta-p/268817</link>
      <description>&lt;H1&gt;&lt;STRONG&gt;Problem&lt;/STRONG&gt;&lt;/H1&gt;
&lt;P&gt;We can sometimes encounter high resource overhead because of the Dynatrace Object named “&lt;STRONG&gt;&lt;EM&gt;DynatraceLogEnrichmentData.combineMDCs”&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;This article will be helpful in understanding the regular working of the Log enrichment component. The technology involved is Java.&lt;/P&gt;
&lt;P&gt;Below is the example screenshot from the Memory profiling page that shows the Dynatrace Object is taking up high memory:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="logsnip2.jpg" style="width: 999px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/26318iED8765266A4A57E8/image-size/large?v=v2&amp;amp;px=999" role="button" title="logsnip2.jpg" alt="logsnip2.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;H1&gt;&amp;nbsp;&lt;/H1&gt;
&lt;H1&gt;&lt;STRONG&gt;Troubleshooting steps&lt;/STRONG&gt;&lt;/H1&gt;
&lt;P&gt;The&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;"DynatraceLogEnrichmentData.combineMDCs"&lt;/EM&gt;&lt;/STRONG&gt;&amp;nbsp;method can be safely disabled&lt;STRONG&gt;&lt;EM&gt;&amp;nbsp;&lt;/EM&gt;&lt;/STRONG&gt;by turning-off the Log Enrichment OneAgent feature for Java from the settings page. Please refer to the screenshot below to make the changes via Global settings:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="logsnip1.jpg" style="width: 999px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/26317iA2FF1FE7CEC3592B/image-size/large?v=v2&amp;amp;px=999" role="button" title="logsnip1.jpg" alt="logsnip1.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;This can also be done via process group settings on a specific application process.&lt;/P&gt;
&lt;P&gt;However, be mindful that this can be disabled only if the Application process does not use log monitoring.&lt;/P&gt;
&lt;H1&gt;&amp;nbsp;&lt;/H1&gt;
&lt;H1&gt;&lt;STRONG&gt;Working/ Expected Behavior&lt;/STRONG&gt;&lt;/H1&gt;
&lt;P&gt;The "Profiling and Optimization" page shows memory allocation. The Dynatrace objects/ methods seen in the above screenshot are freed again.&lt;/P&gt;
&lt;P&gt;This is the so-called Java object churn. It is&amp;nbsp;&lt;EM&gt;not&lt;/EM&gt;&amp;nbsp;a heap dump showing objects still in memory (memory leak).&lt;BR /&gt;It is correct that the method "&lt;STRONG&gt;&lt;EM&gt;DynatraceLogEnrichmentData.combineMDCs&lt;/EM&gt;&lt;/STRONG&gt;" is related to the log enrichment feature. The more logs are enriched, the more often it is called. However, all objects are garbage collected after the method is left.&lt;/P&gt;
&lt;P&gt;We can conclude that this behavior is expected and that there will be no issues as long as the heap memory is stable.&lt;/P&gt;
&lt;H1&gt;&amp;nbsp;&lt;/H1&gt;
&lt;H1&gt;&lt;STRONG&gt;What’s next&lt;/STRONG&gt;&lt;/H1&gt;
&lt;P&gt;If there is suspicion that the memory leak is caused by OneAgent, a full heap dump must be provided, which contains proof of leaking objects.&lt;/P&gt;
&lt;P&gt;A support case can be created in the above scenario for further troubleshooting.&lt;/P&gt;
&lt;P&gt;Note: Prediction of heap usage/ object churn can't be done. The activity of the log enrichment sensor highly depends on the configured environment settings.&lt;BR /&gt;Verbose logging via debug, trace will cause more churn than only logging warnings.&lt;BR /&gt;Also, it depends on their usage of Mapped Diagnostic Context (MDC).&lt;/P&gt;
&lt;P&gt;As the lifetime of the OneAgent objects is very short, the Garbage Collection of the JVM will actually reclaim the memory immediately. Thus, a significant heap increase should not be visible.&lt;/P&gt;</description>
      <pubDate>Mon, 17 Feb 2025 06:57:00 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Troubleshooting/High-resource-overhead-issue-related-to-the-Dynatrace-Log/ta-p/268817</guid>
      <dc:creator>Akshay_Utekar</dc:creator>
      <dc:date>2025-02-17T06:57:00Z</dc:date>
    </item>
  </channel>
</rss>

