Java Memory Management A Comprehensive Guide to Garbage Collection and JVM Tuning
Improve application performance by tuning, monitoring and profiling both the garbage collector and JVMKey Features:Understand the different parts of Java memory and the various garbage collectors so you can select your preferred oneExplore how memory management can help to effectively improve perfor...
Otros Autores: | , |
---|---|
Formato: | Libro electrónico |
Idioma: | Inglés |
Publicado: |
Birmingham :
Packt Publishing, Limited
2022.
|
Edición: | 1st edition |
Materias: | |
Ver en Biblioteca Universitat Ramon Llull: | https://discovery.url.edu/permalink/34CSUC_URL/1im36ta/alma991009703295906719 |
Tabla de Contenidos:
- Cover
- Title Page
- Copyright and Credit
- Dedicated
- Contributors
- Table of Contents
- Preface
- Chapter 1: Different Parts of the Java Memory
- Technical requirements
- Understanding computer memory and Java memory
- Computer memory
- Accessing the main memory
- Overview of the main memory
- Java memory and the JVM
- The JVM
- Memory management and the JVM
- Memory management before Java
- Understanding the JVM's components for memory management
- Runtime data area
- Creating variables in Java
- Primitives and reference types
- Storing variables on the stack
- Current frame and current method
- Elements of the frame
- Values on the stack
- Primitives and wrapper classes
- Creating objects in Java
- Storing objects on the heap
- Exploring the Metaspace
- Summary
- Chapter 2: Primitives and Objects in Java Memory
- Technical requirements
- Understanding primitives on the stack and heap
- Storing objects on the heap
- References
- Objects
- Understanding the differences between references and objects
- Managing object references and security
- Inspecting the escaping references issue
- Summary
- Chapter 3: Zooming in on the Heap Space
- Exploring the different generations on the heap
- Garbage collection roots
- Learning how the spaces are used
- Understanding the minor garbage collection algorithm
- Demonstrating the minor garbage collection algorithm in action
- Summary
- Chapter 4: Freeing Memory with Garbage Collection
- Technical requirements
- Being eligible for GC
- Marking by the garbage collector
- Stop-the-world
- Reference counting and islands of isolation
- Sweeping by the garbage collector
- Normal sweeping
- Sweeping with compacting
- Sweeping with copying
- Exploring GC implementations
- Generational GC
- Serial GC
- Parallel GC
- CMS GC
- G1 GC
- Z GC
- Monitoring GC
- Summary
- Chapter 5: Zooming in on the Metaspace
- JVM usage of the Metaspace
- Class loading
- Releasing Metaspace memory
- Metaspace runs out of memory
- Metaspace size exceeds a JVM-set threshold
- Garbage collection of the Metaspace
- Summary
- Chapter 6: Configuring and Monitoring the Memory Management of the JVM
- Technical requirements
- The basics of JVM tuning for memory management
- Obtaining relevant metrics for memory management
- Well-functioning memory
- Normal latency
- Level of throughput
- Profiling Java applications
- Profiling with jstat and jmap
- Profiling with VisualVM
- Tuning the configurations of the JVM
- Tuning the heap size and thread stack size
- Logging low memory
- Tuning the Metaspace
- Garbage collection tuning
- Chapter 7: Avoiding Memory Leaks
- Technical requirements
- Understanding memory leaks
- Spotting memory leaks
- Heap memory footprint
- Garbage collector activity
- Heap dump
- Avoiding memory leaks
- Common pitfalls and how to avoid them
- Summary
- Index
- Other Books You May Enjoy