java-performance-profiling

Profile Java CPU, allocation, and lock bottlenecks with JFR and async-profiler.

1|Updated Jan 19, 2026
One-click install
npx skills add https://github.com/HZeroxium/cursorkit --skill java-performance-profiling
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: java-performance-profiling
Source: https://github.com/HZeroxium/cursorkit/tree/main/lib/skills/java-backend/java-performance-profiling
Command: npx skills add https://github.com/HZeroxium/cursorkit --skill java-performance-profiling

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill provides a repeatable workflow for diagnosing Java performance issues by combining Java Flight Recorder (JFR) with async-profiler concepts to capture evidence on CPU, allocations, and locks, build hypotheses, ship safe fixes, and verify regressions in production-safe scenarios.

Core Features & Use Cases

  • Repeatable profiling loop: Confirm symptoms, capture evidence, analyze hot paths, and test fixes.
  • Comprehensive coverage: CPU hot paths, allocation hotspots, lock contention, and thread state analysis with JFR-based recording guidance.
  • Verification workflow: Re-measure and document improvements to produce concise, testable outcomes (baselined vs after).
  • Usage scenarios: Production or staging when CPU is high, latency spikes, or memory pressure, with safety considerations for production profiling.

Quick Start

Run a controlled profiling session (30–300s) on a representative workload to identify CPU hot paths, allocations, and locks, then capture a JFR recording and document findings.

Frequently Asked Questions about java-performance-profiling

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

FAQPage Schema
How do I identify Java performance bottlenecks using JFR?

Identify Java performance bottlenecks by running a controlled JFR recording session on a representative workload to capture CPU hot paths, allocation hotspots, and lock contention evidence for structured analysis.

What is the best way to profile CPU hot paths and lock contention in a Java application?

Profile CPU hot paths and lock contention by applying a repeatable workflow that combines JFR and async-profiler concepts to capture evidence on thread states and resource pressure during bounded recording windows.

Can I use async-profiler and JFR for production-safe Java profiling?

Yes, you can use async-profiler and JFR for production-safe Java profiling by running bounded recording windows of 30 to 300 seconds with safety considerations to capture evidence without destabilizing the system.

How do I verify a Java latency fix after resolving allocation hotspots?

Verify a Java latency fix by re-measuring the targeted workload and documenting before and after improvements to validate that the fix resolved the allocation hotspots and produced a safe, testable outcome.

When should I use JFR over other Java profiling tools for latency spikes?

Use JFR for latency spikes when you need a structured, repeatable profiling loop to build hypotheses from CPU and lock evidence, ship safe fixes, and validate regressions in production-like scenarios.

Why does my Java application have high CPU and how do I document the profiling findings?

High CPU in Java applications stems from hot paths or lock contention that you can diagnose by capturing JFR recordings, analyzing the evidence, and documenting findings to produce concise, testable outcomes.