<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.sasgaming.net/index.php?action=history&amp;feed=atom&amp;title=Minecraft%3ACommands%2Fjfr</id>
	<title>Minecraft:Commands/jfr - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.sasgaming.net/index.php?action=history&amp;feed=atom&amp;title=Minecraft%3ACommands%2Fjfr"/>
	<link rel="alternate" type="text/html" href="https://wiki.sasgaming.net/index.php?title=Minecraft:Commands/jfr&amp;action=history"/>
	<updated>2026-04-09T14:33:25Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.8</generator>
	<entry>
		<id>https://wiki.sasgaming.net/index.php?title=Minecraft:Commands/jfr&amp;diff=49713&amp;oldid=prev</id>
		<title>imported&gt;Outrowed: separate WP and JEP linking</title>
		<link rel="alternate" type="text/html" href="https://wiki.sasgaming.net/index.php?title=Minecraft:Commands/jfr&amp;diff=49713&amp;oldid=prev"/>
		<updated>2025-03-30T03:47:01Z</updated>

		<summary type="html">&lt;p&gt;separate WP and JEP linking&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Exclusive|java}}&lt;br /&gt;
&lt;br /&gt;
{{Infobox command&lt;br /&gt;
|name=jfr&lt;br /&gt;
|oplevel=4&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Starts and stops profiling with {{w|Java Flight Recorder}} ([https://openjdk.java.net/jeps/328 JEP]) as well as a few custom events.&lt;br /&gt;
&lt;br /&gt;
==Usage==&lt;br /&gt;
When profiling, it records several information about CPU, memory, and threads usage of the client while it was running, and saves them on a &amp;lt;code&amp;gt;.jfr&amp;lt;/code&amp;gt; file under the {{cd|[[Minecraft:.minecraft]]/debug}} folder.&lt;br /&gt;
&lt;br /&gt;
The file can be opened using an external tool or software, such as [https://visualvm.github.io/ VisualVM] or [https://github.com/openjdk/jmc JMC]. It contains JVM and operating system events, with several &amp;#039;&amp;#039;Minecraft&amp;#039;&amp;#039;-related custom events below:&lt;br /&gt;
&amp;lt;!-- Documentation with names taken from VisualVM program --&amp;gt;&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Network&amp;#039;&amp;#039;&amp;#039; group, which contains:&lt;br /&gt;
**&amp;#039;&amp;#039;&amp;#039;Network Packet Received&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;Network Packet Sent&amp;#039;&amp;#039;&amp;#039;: network packet events, containing information about their protocol ID, packet ID, packet direction (server or client bound), remote address, and bytes size. See [[Minecraft:Java Edition protocol]] for list of protocol and packet IDs.&lt;br /&gt;
**&amp;#039;&amp;#039;&amp;#039;Network Summary&amp;#039;&amp;#039;&amp;#039;: summary information of received and sent packets count and their bytes size.&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Storage&amp;#039;&amp;#039;&amp;#039; group, which contains:&lt;br /&gt;
** &amp;#039;&amp;#039;&amp;#039;Region File Read&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;Region File Write&amp;#039;&amp;#039;&amp;#039;: [[Minecraft:region file]] events, containing information about region and chunk positions, dimension, and type of compression algorithm.&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Ticking&amp;#039;&amp;#039;&amp;#039; group, which only contains a single custom event:&lt;br /&gt;
**&amp;#039;&amp;#039;&amp;#039;Server Tick Time&amp;#039;&amp;#039;&amp;#039;: sampling event of the average server tick duration at one second intervals.&lt;br /&gt;
&lt;br /&gt;
*&amp;#039;&amp;#039;&amp;#039;World Generation&amp;#039;&amp;#039;&amp;#039; group, which contains:&lt;br /&gt;
**&amp;#039;&amp;#039;&amp;#039;Chunk Generation&amp;#039;&amp;#039;&amp;#039;: time taken to generate individual [[Minecraft:chunk]] stages.&lt;br /&gt;
**&amp;#039;&amp;#039;&amp;#039;Create/Load World&amp;#039;&amp;#039;&amp;#039;: initial [[Minecraft:world]] loading duration when loading a world.&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;code&amp;gt;.jfr&amp;lt;/code&amp;gt; file is accompanied by a summary [[Minecraft:JSON]] report is written both to the log file and in the debug folder.&lt;br /&gt;
&lt;br /&gt;
== Syntax ==&lt;br /&gt;
:&amp;lt;code&amp;gt;jfr start&amp;lt;/code&amp;gt;&lt;br /&gt;
:: Start JFR profiling.&lt;br /&gt;
:&amp;lt;code&amp;gt;jfr stop&amp;lt;/code&amp;gt;&lt;br /&gt;
:: Stop JFR profiling.&lt;br /&gt;
&lt;br /&gt;
== Result ==&lt;br /&gt;
{{Result table|onlyje=1}}&lt;br /&gt;
{{Result table|The command is incomplete, or any argument is not specified correctly.|unparseable}}&lt;br /&gt;
{{Result table|cmd=/jfr start|A jfr profiler has already been started.|fail}}&lt;br /&gt;
{{Result table|cmd=/jfr stop|There&amp;#039;s no jfr profiler running.}}&lt;br /&gt;
{{Result table|cmd=|succeed}}&lt;br /&gt;
{{Result table}}&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
{{Output table}}&lt;br /&gt;
{{Output table|edition=je|On fail|N/A|0|0}}&lt;br /&gt;
{{Output table|On success|N/A|1|1}}&lt;br /&gt;
{{Output table}}&lt;br /&gt;
&lt;br /&gt;
== History ==&lt;br /&gt;
{{HistoryTable&lt;br /&gt;
|{{HistoryLine|java}}&lt;br /&gt;
|{{HistoryLine||1.18|dev=21w37a|Added {{cmd|jfr|link=none}}.}}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Navigation ==&lt;br /&gt;
{{Navbox commands}}&lt;br /&gt;
&lt;br /&gt;
[[Minecraft:de:Befehl/jfr]]&lt;br /&gt;
[[Minecraft:es:Comandos/jfr]]&lt;br /&gt;
[[Minecraft:ja:コマンド/jfr]]&lt;br /&gt;
[[Minecraft:lzh:令/jfr]]&lt;br /&gt;
[[Minecraft:pt:Comandos/jfr]]&lt;br /&gt;
[[Minecraft:zh:命令/jfr]]&lt;/div&gt;</summary>
		<author><name>imported&gt;Outrowed</name></author>
	</entry>
</feed>