When I start a java Minecraft server, I get a message from Sun that says the code is using a “terminally deprecated method”. Here’s the message:
C:\Users\Jim\AppData\Roaming\.MCServer - Gideon>java -Xmx2G -Xms2G -jar server.jar nogui --bonusChest
Starting net.minecraft.server.Main
WARNING: A restricted method in java.lang.System has been called
WARNING: java.lang.System::load has been called by com.sun.jna.Native in an unnamed module (file:/C:/Users/Jim/AppData/R
oaming/.MCServer%20-%20Gideon/libraries/net/java/dev/jna/jna/5.17.0/jna-5.17.0.jar)
WARNING: Use --enable-native-access=ALL-UNNAMED to avoid a warning for callers in this module
WARNING: Restricted methods will be blocked in a future release unless native access is enabled
WARNING: A terminally deprecated method in sun.misc.Unsafe has been called
WARNING: sun.misc.Unsafe::objectFieldOffset has been called by org.joml.MemUtil$MemUtilUnsafe (file:/C:/Users/Jim/AppDat
a/Roaming/.MCServer%20-%20Gideon/libraries/org/joml/joml/1.10.8/joml-1.10.8.jar)
WARNING: Please consider reporting this to the maintainers of class org.joml.MemUtil$MemUtilUnsafe
WARNING: sun.misc.Unsafe::objectFieldOffset will be removed in a future release
[20:39:07] [ServerMain/INFO]: Environment: Environment[sessionHost=https://sessionserver.mojang.com, servicesHost=https:
//api.minecraftservices.com, profilesHost=https://api.mojang.com, name=PROD]
[20:39:10] [ServerMain/INFO]: Loaded 1515 recipes
The game starts normally, so it seems this is just a warning from Sun. But it implies that the code is going to fail at some point in the future.
Environment
Windows 10, homemade PC, latest Java and JRE. Minecraft client version 26.1.1, but this started at least at 26.1.
This is an issue within the libraries JNA and JOML, and will be resolved by them. This is not an issue with the game.