How to Solve OutOfMemoryError: GC Overhead Limit Exceeded

In this post, we explored the 'java.lang.OutOfMemoryError: GC overhead limit exceeded', a common challenge for Java developers. We delved into its causes, including increased traffic volume and memory leaks, as well as potential solutions such as fixing memory leaks and increasing heap size. Troubleshooting tips, including capturing and analyzing heap dumps, were also discussed to equip developers in conquering this issue.

String Deduplication in Java

In this article, we’ll learn how to improve the performance of the applications that tend to use most of the space due to extensive usage of Strings. There’s no need to store more than one instance of immutable objects in our heap, and String is a good example. Object Allocation Let’s briefly refresh the information... Continue Reading →

Optimizing the Capacity of a HashMap

Many of us know that allocating more memory than we need may negatively affect the performance of our application. Thus, creating the Lists using a constructor that takes a capacity may make a significant difference. However, this optimization step might not be so straightforward while using Maps. In this article, we’ll learn how to identify... Continue Reading →

Actions on OutOfMemoryErrors

Everyone has at least once seen a failing application due to OutOfMemoryError. This error happens because the application cannot allocate the required memory. The specific reason for this problem may differ depending on the severity and heap section affected. However, in any case, we would like to have some actions prepared for this. In this... Continue Reading →

Virtual Threads – A Definite Advantage

It's great to explore the world of Virtual Threads, a powerful feature in Java that promises to revolutionize multi-threaded applications. In this article, we'll delve into how Virtual Threads can enhance your application's performance and scalability, all while keeping thread management overhead very minimal. Let's embark on this journey to harness the full potential of... Continue Reading →

Simulating & troubleshooting OOMError in Kotlin

In this series of simulating and troubleshooting performance problems in Kotlin, let’s discuss how to simulate the ‘java.lang.OutOfMemoryError: Java Heap space’ problem. ‘java.lang.OutOfMemoryError: Java Heap space’ will be thrown by the application, when it generates more objects than the maximum configured heap size. Video: To see the visual walk-through of this post, click below: https://youtu.be/y9Iydjrnix8... Continue Reading →

Troubleshooting Microservice’s OutOfMemoryError: Metaspace

Recently we confronted an interesting 'java.lang.OutOfMemoryError: Metaspace' problem in a Microservice application. This Microservice application will run smoothly for initial few hours, later it will start to throw java.lang.OutOfMemoryError: Metaspace. In this post let me share the steps we pursued to troubleshoot this problem. Video: To see the visual walk-through of this post, click below:... Continue Reading →

Up ↑