Simulating & troubleshooting Thread leak in Kotlin

This post explains how to simulate and troubleshoot thread leaks in Kotlin, focusing on generating a 'java.lang.OutOfMemoryError: unable to create new native thread.’ It describes a sample program that infinitely creates non-terminating threads and outlines both manual and automated approaches to diagnose and resolve the issue, emphasizing the use of tools like yCrash.

Simulating & troubleshooting BLOCKED threads in Kotlin 

This article explores how threads enter a BLOCKED state in Kotlin due to lock contention. It includes a sample program demonstrating how ten threads can be blocked when accessing a synchronized method that forces them into prolonged sleep. Additionally, it discusses methods for diagnosing blocked threads, including both manual and automated approaches using tools like yCrash.

J4K Conference 2022 – 16 ARTIFACTS TO CAPTURE WHEN THERE IS A PRODUCTION PROBLEM

J4K 2022 is a conference for Java Developers focused on Kubernetes, taking place on September 28th. Architect Ram Lakshmanan presented a talk on capturing 16 essential artifacts when facing production issues. The session highlighted effective tools, techniques, and tips for analyzing these artifacts in cloud and container environments.

Troubleshooting deadlock in an Apache opensource library

Apache PDFBox is a Java library for handling PDF documents. A recent deadlock issue was identified, blocking two threads that were waiting for each other's resources. Troubleshooting involved capturing thread dumps and analyzing them, which led to filing a bug report with the Apache PDFBox team, who promptly addressed the issue.

Simulating & troubleshooting deadlock in Kotlin

This post discusses deadlocks in multi-threaded applications, particularly in Kotlin. It defines deadlock, illustrates it with an example involving trains, and provides a sample Kotlin program demonstrating deadlock between two threads. The post also suggests troubleshooting methods, including using thread dumps and the yCrash tool for root cause analysis.

Java Hashtable, HashMap, ConcurrentHashMap – Performance impact

This post examines the performance characteristics of HashMap, Hashtable, and ConcurrentHashMap through practical examples. It finds that while HashMap is fastest, it is not thread-safe, risking infinite loops. ConcurrentHashMap offers comparable speed with thread safety. Hashtable, however, is significantly slower due to synchronization limiting thread access.

Java class loading – performance impact!

The java.lang.ClassLoader#loadClass() API is essential for loading Java classes but can degrade application performance due to thread contention. Frequent calls can cause threads to block, impacting responsiveness. To mitigate these issues, it's advised to load classes once at startup and reuse them, rather than repeatedly during execution.

“Learn yCrash” series

yCrash addresses the limitations of traditional Application Performance Monitoring tools by providing insights into the root causes of problems. It captures and analyzes various technology stack artifacts like logs and dumps. NaveenKumar Namachivayam offers a video series to guide users in learning to utilize yCrash effectively.

Memory leak due to improper exception handling

The post discusses a memory leak problem encountered in a Java application running on AWS. After initial unresponsiveness, the yCrash tool identified the leak stemmed from an anonymous inner class. The issue was resolved by moving the 'pm.stopReporting()' method into a 'finally' clause, ensuring proper cleanup and garbage collection.