Minecraft:Commands/jfr: Difference between revisions
More actions
imported>Outrowed separate WP and JEP linking |
Remove broken links to missing pages |
||
| Line 9: | Line 9: | ||
==Usage== | ==Usage== | ||
When profiling, it records several information about CPU, memory, and threads usage of the client while it was running, and saves them on a <code>.jfr</code> file under the {{cd| | When profiling, it records several information about CPU, memory, and threads usage of the client while it was running, and saves them on a <code>.jfr</code> file under the {{cd|.minecraft/debug}} folder. | ||
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 ''Minecraft''-related custom events below: | 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 ''Minecraft''-related custom events below: | ||
<!-- Documentation with names taken from VisualVM program --> | <!-- Documentation with names taken from VisualVM program --> | ||
* '''Network''' group, which contains: | * '''Network''' group, which contains: | ||
**'''Network Packet Received''' and '''Network Packet Sent''': network packet events, containing information about their protocol ID, packet ID, packet direction (server or client bound), remote address, and bytes size. See | **'''Network Packet Received''' and '''Network Packet Sent''': network packet events, containing information about their protocol ID, packet ID, packet direction (server or client bound), remote address, and bytes size. See Java Edition protocol for list of protocol and packet IDs. | ||
**'''Network Summary''': summary information of received and sent packets count and their bytes size. | **'''Network Summary''': summary information of received and sent packets count and their bytes size. | ||
* '''Storage''' group, which contains: | * '''Storage''' group, which contains: | ||
** '''Region File Read''' and '''Region File Write''' | ** '''Region File Read''' and '''Region File Write''': region file events, containing information about region and chunk positions, dimension, and type of compression algorithm. | ||
* '''Ticking''' group, which only contains a single custom event: | * '''Ticking''' group, which only contains a single custom event: | ||
| Line 24: | Line 24: | ||
*'''World Generation''' group, which contains: | *'''World Generation''' group, which contains: | ||
**'''Chunk Generation''': time taken to generate individual | **'''Chunk Generation''': time taken to generate individual chunk stages. | ||
**'''Create/Load World''': initial | **'''Create/Load World''': initial world loading duration when loading a world. | ||
The <code>.jfr</code> file is accompanied by a summary [[Minecraft:JSON]] report is written both to the log file and in the debug folder. | The <code>.jfr</code> file is accompanied by a summary [[Minecraft:JSON]] report is written both to the log file and in the debug folder. | ||
| Line 58: | Line 58: | ||
{{Navbox commands}} | {{Navbox commands}} | ||
de:Befehl/jfr | |||
es:Comandos/jfr | |||
ja:コマンド/jfr | |||
lzh:令/jfr | |||
pt:Comandos/jfr | |||
zh:命令/jfr | |||
Revision as of 15:44, 9 April 2026
Starts and stops profiling with Template:W (JEP) as well as a few custom events.
Usage
When profiling, it records several information about CPU, memory, and threads usage of the client while it was running, and saves them on a .jfr file under the Template:Cd folder.
The file can be opened using an external tool or software, such as VisualVM or JMC. It contains JVM and operating system events, with several Minecraft-related custom events below:
- Network group, which contains:
- Network Packet Received and Network Packet Sent: network packet events, containing information about their protocol ID, packet ID, packet direction (server or client bound), remote address, and bytes size. See Java Edition protocol for list of protocol and packet IDs.
- Network Summary: summary information of received and sent packets count and their bytes size.
- Storage group, which contains:
- Region File Read and Region File Write: region file events, containing information about region and chunk positions, dimension, and type of compression algorithm.
- Ticking group, which only contains a single custom event:
- Server Tick Time: sampling event of the average server tick duration at one second intervals.
- World Generation group, which contains:
- Chunk Generation: time taken to generate individual chunk stages.
- Create/Load World: initial world loading duration when loading a world.
The .jfr file is accompanied by a summary Minecraft:JSON report is written both to the log file and in the debug folder.
Syntax
jfr start- Start JFR profiling.
jfr stop- Stop JFR profiling.
Result
Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table
Output
Template:Output table Template:Output table Template:Output table Template:Output table
History
de:Befehl/jfr es:Comandos/jfr ja:コマンド/jfr lzh:令/jfr pt:Comandos/jfr zh:命令/jfr