v2.0 is now live

Java Profiling,
Reimagined.

Zero-setup, runtime-attach profiler that lives in your terminal and integrates seamlessly with IntelliJ IDEA.

bash
$ leanj attach --pid 12345
✔ Attached to process 12345 (Spring Boot)
ℹ Starting sampler at 10ms interval...
⚠ High CPU usage detected in com.example.MyService.process()
$ _

Why Developers Love LeanJ

Built for speed, simplicity, and actionable insights.

Runtime Attach

Attach to any running JVM process instantly without restarting your application. Zero downtime analysis.

Visualized in IDE

Metrics appear directly in IntelliJ via CodeVision. See latency and allocs right above your methods.

Resources Friendly

Extremely low overhead (~1%). Uses async sampling and efficient bytecode instrumentation.

Docker Native

Auto-discovery of JVMs inside Docker containers. Just mount the socket and go.

Flame Graphs

Generate interactive flame graphs to visualize performance bottlenecks instantly.

CI/CD Ready

Scriptable CLI allows you to run profiling sessions as part of your automated tests.

Zero to Profiling in Seconds

1

Start Controller

Run the lightweight daemon that manages connections.

leanj controller start
2

Attach Agent

Inject the agent into any local or remote JVM.

leanj attach --pid <id>
3

Analyze

Watch real-time metrics flow into your IDE or terminal.

Frequently Asked Questions

Common questions about functionality and compatibility.

Is it safe for production?

Yes. The profiler is designed with low-overhead sampling (approx 1-2%) and has been battle-tested in high-load production environments.

What Java versions are supported?

LeanJ requires Java JDK 11 or higher. It works with all modern Java versions including JDK 11, 17, 21, and later versions.

Do I need to restart my application?

No. One of the key features is runtime attachment - you can attach the profiler to any running JVM process without restarting your application. This enables zero-downtime performance analysis.

Is it free and open source?

Yes, LeanJ is completely free and open source. The source code is available on GitHub under an open source license. You can use it for both personal and commercial projects.

Can I use it without IntelliJ IDEA?

Absolutely. While IntelliJ integration provides inline hints and visualizations, the CLI works independently. You can profile applications, view metrics, and generate flame graphs entirely from the command line.

What operating systems are supported?

LeanJ supports Windows, Linux, and macOS. Pre-built binaries are available for all three platforms. The CLI and agent work consistently across all supported operating systems.

Does it support remote debugging?

Absolutely. You can connect the CLI to a remote controller instance via HTTP to profile applications on different servers.

What is the performance overhead?

The profiler is designed with minimal overhead, typically around 1-2% CPU overhead. It uses efficient async sampling and bytecode instrumentation techniques to minimize impact on your application's performance.

How does Docker integration work?

Docker containers are automatically discovered when the agent is configured via JAVA_TOOL_OPTIONS. Simply mount the agent JAR and set the environment variable - the profiler will automatically register with the controller for easy profiling of containerized applications.

Can I profile applications in Kubernetes?

Yes. You can profile Java applications running in Kubernetes by configuring the agent via environment variables in your deployment. The profiler supports remote connections, allowing you to profile applications across different pods and namespaces.

What IntelliJ IDEA versions are supported?

The IntelliJ plugin requires IntelliJ IDEA 2023.1 or later. It has been tested up to version 2025.2. The plugin provides CodeVision inline hints, showing latency and allocation metrics directly above your methods in the editor.

How does it differ from JVM built-in profilers?

Unlike JVM built-in profilers, LeanJ provides always-on IDE integration with inline hints, making performance data visible directly in your code. It's designed for continuous profiling during development rather than periodic deep-dive analysis.

How does it compare to JProfiler/YourKit?

LeanJ focuses on 'always-on' availability and IDE integration rather than deep-dive snapshots. It's lighter and faster for day-to-day dev loops.

Boost Your Java Performance Today

Open source, free to use, and community driven.