subject: Resolving Memory Leaks In .net Applications [print this page] Mysterious memory consumption can cause tremendous problems in production applications""especially when default JVM settings are used that end up causing performance issues. You should be able to troubleshoot andidentify memory leaks even in a high-volume production environment.
Understand True Utilization of Memory Pools
Using the right APM solutions can help you identify memory leaks in .NET by monitoring the different memory pool sizes over time. This helps you understand just how close your application is to memory leaks in .NET so you can better fine tune your memory settings. For example, Out of Memory Exceptions can occur when PermGen space is exhausted by application code that is sometimes bigger than the default Perm Gen space in memory (typically 64-128MB).
Resolving Memory Leaks in Java Applications
Mysterious memory consumption can cause tremendous problems in production applications""especially when default JVM settings are used that end up causing performance issues. AppDynamics can help you troubleshoot and identify memory leaks even in a high-volume production environment.
Understand True Utilization of Memory Pools
Using a solution like AppDynamics you can easily monitor the different memory pool sizes over time to understand just how close your application is to getting a Java memory leak so you can better fine tune your JVM memory settings and prevent Java memory leaks. For example, Out of memory Exceptions can occur when PermGen space is exhausted by application code that is sometimes bigger than the default Perm Gen space in memory (typically 64-128MB).
Don"t Fear Large Amounts of Data
Another common reason for Out of memory exceptions is when the application queries large amounts of data from relational databases and tries to persist and process it in .NET memory. With the right performance monitoring software you can detect memory leaks in .NET, identify memory leaks, and also track heap usage over time, object count and physical size (MB) of the objects residing in memory, giving you great visibility into how much data is being persisted in the Windows OS instance at any one time and how much of your memory is being exhausted by different types objects and data structures. You can also correlate this information with garbage collection cycles to understand how often memory is reclaimed by the server. Garbage Collection is a "stop the world" event in the server so it"s important to identify how frequently this occurs and what impact it can have on your application response times.
Identify the Source of Memory Leaks""Fast
If you indeed have memory leaks in .NET, let"s face it: spending hours trawling through thread dumps and profilers isn"t fun. And you don"t want to try a heap dump when the overhead could potentially bring down your app. But using performance monitoring software can help to resolve these issues in record time.