jvm-advanced

Tunes JVM garbage collection, memory, and profiling with G1GC, ZGC, JFR, and async-profiler.

2|Updated Mar 15, 2025
One-click install
npx skills add https://github.com/dandudzi/dotfiles --skill jvm-advanced
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: jvm-advanced
Source: https://github.com/dandudzi/dotfiles/tree/main/dot_claude/skills/jvm-advanced
Command: npx skills add https://github.com/dandudzi/dotfiles --skill jvm-advanced

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill helps you optimize Java Virtual Machine (JVM) performance, reduce memory usage, and leverage GraalVM for native image compilation, leading to faster, more efficient applications.

Core Features & Use Cases

  • JVM Tuning: Configure Garbage Collection (GC) like G1GC and ZGC, manage memory, and analyze performance with JFR and async-profiler.
  • Native Image Compilation: Compile Java applications into standalone executables with GraalVM, drastically reducing startup time and memory footprint.
  • Use Case: Optimize a Spring Boot microservice to handle peak loads with minimal latency by tuning its JVM GC settings and container awareness, or compile it into a native image for serverless deployments.

Quick Start

Use the jvm-advanced skill to tune the G1GC garbage collector for a Spring Boot application with a target pause time of 200ms and a heap size of 4GB.

Frequently Asked Questions about jvm-advanced

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I tune G1GC for a Spring Boot application to meet a target pause time?

Tune G1GC for Spring Boot by configuring target pause times and heap sizes to optimize garbage collection. This Skill provides strategies to set parameters like a 200ms target pause time and 4GB heap for managing memory under peak loads.

What is the best way to reduce Java application startup time for serverless deployments?

Reduce Java startup time using GraalVM native image compilation to create standalone executables. This Skill covers compiling applications into native images, drastically minimizing startup time and memory footprint for serverless environments.

Can I use ZGC to minimize latency in containerized JVM applications?

Yes, you can use ZGC to minimize latency in containerized JVM applications. This Skill provides advanced JVM tuning strategies for configuring ZGC and ensuring container awareness to handle peak loads efficiently.

How do I profile JVM performance using async-profiler and JFR?

Profile JVM performance using async-profiler and Java Flight Recorder (JFR) to analyze application bottlenecks. This Skill details how to leverage these profiling tools to examine memory management and execution performance.

Does GraalVM native image compilation require reflection configuration for Spring Boot?

Yes, GraalVM native image compilation requires reflection configuration for Spring Boot applications. This Skill covers reflection configuration and Spring Boot AOT strategies to properly compile applications into native executables.

When should I not use GraalVM native compilation for my JVM application?

Avoid GraalVM native compilation when application startup time is not critical or when complex dynamic reflection makes configuration impractical. This Skill outlines trade-offs between traditional JVM tuning and native image strategies.