Dynamic Class-File Constants
Dynamic Class-File Constants Read More »
Your blog category
ZGC (Z Garbage Collector) is a scalable, low-latency garbage collector introduced in Java 11 (JEP 333) and production-ready in Java 15. Designed for applications requiring minimal pause times and handling large heaps (multi-terabyte), ZGC achieves pause times typically under 10ms, regardless of heap size, making it ideal for latency-sensitive systems. It’s enabled with -XX:+UseZGC. Key
ZGC: A Scalable Low-Latency Garbage Collector Read More »
Epsilon is a no-op garbage collector in Java (introduced in JEP 318, Java 11) that allocates memory but does not reclaim it, leading to a JVM crash with an OutOfMemoryError when the heap is exhausted. It’s enabled with -XX:+UnlockExperimentalVMOptions -XX:+UseEpsilonGC. Below, I’ll explain Epsilon briefly and provide a sample use case with code to demonstrate
Epsilon: A No-Op Garbage Collector Read More »
Java 11, released in September 2018, includes support for Unicode 10.0.0, which was a significant update to the Unicode standard. Below is a concise overview of Unicode 10 support in Java 11 and its relevance as a feature: Unicode 10 Support in Java 11 Unicode Version: Java 11 supports Unicode 10.0.0, released in June 2017,
Unicode 10 Support Read More »
The Single-File Source-Code Programs feature, introduced in Java 11 via JEP 330, allows developers to execute a Java source file directly using the java launcher without explicitly compiling it first. This feature is particularly useful for beginners learning Java, writing small utility programs, or quickly testing code snippets. Important Points Purpose: Simplifies running single-file Java
Single-File Source-Code Programs Read More »
Introduced in Java 11 via JEP 323, this feature allows the var keyword (originally introduced for local variables in Java 10) to be used in lambda parameter declarations. It enables type inference for lambda parameters, reducing verbosity and aligning lambda syntax with local variable declarations. Syntax You can use var instead of explicit types in
Local-Variable Syntax for Lambda Parameters Read More »
UI-specific exception handling patterns are essential for event-driven applications to maintain smooth operations and ensure a seamless user experience. These patterns help in managing errors effectively without disrupting the application’s functionality. Below are key UI-specific exception handling patterns along with guidance on when to use them and the reasoning behind their application. 1. Try-Catch Blocks
UI-specific exception handling patterns Read More »
Event-driven exception handling is a crucial concept in developing robust and user-friendly applications, particularly in GUI (Graphical User Interface) environments where the flow of control is determined by user interactions or system events. In these environments, managing exceptions effectively is key to ensuring the application continues running smoothly even when errors occur. Here’s a deeper
Handling event-driven exceptions Read More »
Exception handling in graphical user interface (GUI) applications is a crucial aspect of robust application design. Since GUI applications are typically event-driven, they need to handle a wide variety of situations where errors might occur—ranging from user inputs to file or network operations. Below are the key principles and concepts of exception handling in GUI
Exception handling in graphical user interfaces Read More »
Connection Pooling Connection pooling is a performance-enhancing technique used in database programming. Rather than creating a new database connection each time it’s needed — which is time-consuming and resource-intensive — connection pooling allows applications to reuse a pool of pre-established connections. How It Works: A pool of connections is created and maintained in memory. When
Connection pooling and exceptions Read More »