.NET Framework APM agent Memory leak

Kibana version: 7.8.0

Elasticsearch version: 7.8.0

APM Server version: 7.8.0

APM Agent language and versions:

  • Elastic.Apm.AspNetFullFramework 1.6.1

  • Elastic.Apm.EntityFramework6 1.6.1

Original install method (e.g. download page, yum, deb, from source, etc.) and version: Elastic Cloud

Description of the problem including expected versus actual behavior.: Memory leak occurs when Asp.Net Full Framework and EF 6 agents are running. Memory for this server usually sits between 75% to 85% usage. With agent install the system slowly climbs to 100% memory usage and crashes. This is using the default settings for the agents.

@baronson, I'll look deeper into this, couple of ideas:

  • Can you try putting into the application and make sure this executes during app startup?
Activity.DefaultIdFormat = ActivityIdFormat.Hierarchical;
Activity.ForceDefaultIdFormat = true;

This is a related bug which was fixed - if executing that code fixes the issue then it's a leftover edge case and we'll need to do another iteration on it.

  • Do you use the Public Agent API or is it just auto instrumentation?
  • Any chance giving us a memory dump? And also an agent log on trace level where you let the app run until it collects couple of requests?

The 1. point would be worth trying first - that'd already give me some good hints.

Thanks,
Greg

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.