Wednesday, May 27, 2020

Choosing the Best Garbage Collection Algorithm for Better Performance in Java

In this article, I’m going to explain how Garbage Collection works behind the scene to free up memory. Java memory management has emerged a lot over the past few Java releases. Understanding the different GC algorithms will help you better to tune it (if required) depending upon the different performance issues we see in many of the Java-based application performance testing. When your Java application runs, it creates objects which take up memory space. As long as the object is being used (i.e referred by the application somewhere), it is going to occupy the memory. When the object is no longer used (for example, when you cleanly close a DB connection), the space occupied by the object can be reclaimed by Garbage collection. 

How to choose the best garbage collector for your use case for any Java-based application performance testing? Before we go into that question lets talk some of the below basic concepts. 



from DZone.com Feed https://ift.tt/2XyMbfK

No comments:

Post a Comment