3

I want to run a java application with JFR enabled. When I start my application as below java -XX:+UnlockCommercialFeatures -XX:StartFlightRecording

I get following error **Unrecognized VM option -XX:+UnlockCommercialFeatures*

Does OPENJDK 1.8.0_242 supports Java Flight Recorder? build is 1.8.0_242-b07

Krishan
  • 1,165
  • 2
  • 6
  • 9
  • It sounds like "no, but a future point release of OpenJDK 8 will": https://www.infoq.com/news/2020/02/jfr-coming-to-openjdk-8/ – Joseph Sible-Reinstate Monica Apr 20 '20 at 23:54
  • Possible duplicate: https://stackoverflow.com/questions/60150612/jdk-flight-recorder-backport-in-redhat-openjdk-8/60295801#comment109275237_60295801 – Matécsa Andrea Jul 10 '20 at 08:23
  • JFR was originally a proprietary feature of the Oracle JDK, so -XX:+UnlockCommercialFeatures applies only to Oracle JDK. Oracle JDK 11 emits a warning when using the -XX:+UnlockCommercialFeatures option, whereas OpenJDK doesn’t recognize this option and reports an error. (ref https://dzone.com/articles/using-java-flight-recorder-with-openjdk-11-1) – rlovtang Sep 18 '20 at 09:37

2 Answers2

3

No it does not. As per the release notes for openjdk8u262, it is supported in OpenJDK 8 update 262.

New features - JDK-8223147: JFR Backport

djpanda
  • 835
  • 10
  • 20
1

Oracle open-sourced both Flight Recorder and Mission Recorder as sub-projects housed on the OpenJDK project. Builds available from vendors such as Azul Systems, Oracle, and others. Some may be free-of-cost, some may not; read the terms.

Zulu Community edition, by Azul Systems

Azul Systems, Inc. is currently shipping their Zulu Community product built on OpenJDK. Java Flight Recorder and Mission Control are both included for Java 8 according to their feature matrix.

Also included in their commercial product, Zulu Enterprise.

Caveat: I have not used Flight Recorder with either Zulu. Just found it from some web searching.


By the way, TLS improvements are also being back-ported to Java 8.

Basil Bourque
  • 303,325
  • 100
  • 852
  • 1,154