0

I just learned Java Mission Control. I thought about how to make Java Flight Recorder with Java code. I analyzed the heap file with lots of different tools, but this time I want to do it with code.

karel
  • 5,489
  • 46
  • 45
  • 50

1 Answers1

2

Here are the docs for reading a .jfr file with Java 11 - https://docs.oracle.com/en/java/javase/11/docs/api/jdk.jfr/jdk/jfr/consumer/package-summary.html

There are other (not as supported) APIs for reading older .jfr files (from JDK 8), both with the JFR parser built into the JDK, and the JFR parser built into Java Mission Control.

Klara
  • 2,935
  • 22
  • 19
  • JMC has a parser for hprof files, but it is only used internally. I assume there are other open source projects that have hprof parsers, maybe this one?: https://github.com/eaftan/hprof-parser – Klara Mar 12 '19 at 08:25