Reload consumes main thread
SlimeDog opened this issue ยท 8 comments
Skript/Server Version
> skript info
[18:17:42 INFO]: [Skript] Skript's aliases can be found here: https://github.com/SkriptLang/skript-aliases
[18:17:42 INFO]: [Skript] Skript's documentation can be found here: https://docs.skriptlang.org/
[18:17:42 INFO]: [Skript] Skript's tutorials can be found here: https://docs.skriptlang.org/tutorials
[18:17:42 INFO]: [Skript] Server Version: git-Paper-407 (MC: 1.20.4)
[18:17:42 INFO]: [Skript] Skript Version: 2.8.1 (skriptlang-github)
[18:17:42 INFO]: [Skript] Installed Skript Addons: None
[18:17:42 INFO]: [Skript] Installed dependencies:
[18:17:42 INFO]: [Skript] - Vault v1.7.3-b131
[18:17:42 INFO]: [Skript] - WorldGuard v7.0.10-SNAPSHOT+2260-c7319f1
Bug Description
sk reload all
or sk reload aliases
consumes main thread, thereby causes serve to drop into a hole
Expected Behavior
asynchronous reload, so that server doesn't all in a hole
Steps to Reproduce
- sk reload all
Errors or Screenshots
> sk reload all
[18:13:50 INFO]: [Skript] Reloading the config, aliases and all scripts...
[18:14:00 ERROR]: --- DO NOT REPORT THIS TO PAPER - THIS IS NOT A BUG OR A CRASH - git-Paper-407 (MC: 1.20.4) ---
[18:14:00 ERROR]: The server has not responded for 10 seconds! Creating thread dump
[18:14:00 ERROR]: ------------------------------
[18:14:00 ERROR]: Server thread dump (Look for plugins here before reporting to Paper!):
[18:14:00 ERROR]: ------------------------------
[18:14:00 ERROR]: Current Thread: Server thread
[18:14:00 ERROR]: PID: 43 | Suspended: false | Native: false | State: RUNNABLE
[18:14:00 ERROR]: Stack:
[18:14:00 ERROR]: io.papermc.paper.util.table.ZeroCollidingReferenceStateTable.get(ZeroCollidingReferenceStateTable.java:124)
[18:14:00 ERROR]: net.minecraft.world.level.block.state.StateHolder.setValue(StateHolder.java:108)
[18:14:00 ERROR]: org.bukkit.craftbukkit.v1_20_R3.block.data.CraftBlockData.merge(CraftBlockData.java:126)
[18:14:00 ERROR]: org.bukkit.craftbukkit.v1_20_R3.block.data.CraftBlockData.matches(CraftBlockData.java:151)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.bukkitutil.block.NewBlockCompat$NewBlockValues.match(NewBlockCompat.java:112)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.ItemData.matchAlias(ItemData.java:328)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.AliasesMap.exactMatch(AliasesMap.java:215)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.AliasesProvider.addAlias(AliasesProvider.java:294)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.AliasesParser.loadSingleAlias(AliasesParser.java:694)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.AliasesParser.loadAlias(AliasesParser.java:603)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.AliasesParser.load(AliasesParser.java:121)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.Aliases.load(Aliases.java:504)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.Aliases.load(Aliases.java:490)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.Aliases.lambda$loadDirectory$1(Aliases.java:473)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.Aliases$$Lambda/0x00007f96b9b30f68.accept(Unknown Source)
[18:14:00 ERROR]: [email protected]/java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:184)
[18:14:00 ERROR]: [email protected]/java.util.stream.SortedOps$RefSortingSink$$Lambda/0x00007f96b8271410.accept(Unknown Source)
[18:14:00 ERROR]: [email protected]/java.util.ArrayList.forEach(ArrayList.java:1596)
[18:14:00 ERROR]: [email protected]/java.util.stream.SortedOps$RefSortingSink.end(SortedOps.java:395)
[18:14:00 ERROR]: [email protected]/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:510)
[18:14:00 ERROR]: [email protected]/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499)
[18:14:00 ERROR]: [email protected]/java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:151)
[18:14:00 ERROR]: [email protected]/java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:174)
[18:14:00 ERROR]: [email protected]/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
[18:14:00 ERROR]: [email protected]/java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:596)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.Aliases.loadDirectory(Aliases.java:466)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.Aliases.loadInternal(Aliases.java:431)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.aliases.Aliases.load(Aliases.java:387)
[18:14:00 ERROR]: Skript-2.8.1.jar//ch.njol.skript.SkriptCommand.onCommand(SkriptCommand.java:138)
[18:14:00 ERROR]: org.bukkit.command.PluginCommand.execute(PluginCommand.java:45)
[18:14:00 ERROR]: org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:155)
[18:14:00 ERROR]: org.bukkit.craftbukkit.v1_20_R3.CraftServer.dispatchCommand(CraftServer.java:987)
[18:14:00 ERROR]: org.bukkit.craftbukkit.v1_20_R3.CraftServer.dispatchServerCommand(CraftServer.java:972)
[18:14:00 ERROR]: net.minecraft.server.dedicated.DedicatedServer.handleConsoleInputs(DedicatedServer.java:500)
[18:14:00 ERROR]: net.minecraft.server.dedicated.DedicatedServer.tickChildren(DedicatedServer.java:447)
[18:14:00 ERROR]: net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1515)
[18:14:00 ERROR]: net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1216)
[18:14:00 ERROR]: net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:319)
[18:14:00 ERROR]: net.minecraft.server.MinecraftServer$$Lambda/0x00007f96b8be7620.run(Unknown Source)
[18:14:00 ERROR]: [email protected]/java.lang.Thread.runWith(Thread.java:1596)
[18:14:00 ERROR]: [email protected]/java.lang.Thread.run(Thread.java:1583)
[18:14:00 ERROR]: ------------------------------
[18:14:00 ERROR]: --- DO NOT REPORT THIS TO PAPER - THIS IS NOT A BUG OR A CRASH ---
[18:14:00 ERROR]: ------------------------------
[18:14:04 INFO]: Loaded 232512 aliases in 13291ms
[18:14:05 INFO]: [Skript] Successfully reloaded the config, aliases and all scripts. (14938ms)
[18:14:05 WARN]: Can't keep up! Is the server overloaded? Running 14897ms or 297 ticks behind
Other
No response
Agreement
- I have read the guidelines above and affirm I am following them with this report.
Duplicate #6179
Then that is not working. It's been set to 240 since I don't know when. Per the above, the reload is taking 15 seconds.
As I said earlier, your server is fine. All that's happening is that Paper is telling you that your server has been frozen for 10s or more. You can ignore it.
If you want to make the warning only trigger at 20s, or another time, you can change the following values in paper-global.yml;
watchdog:
early-warning-delay: 10000
early-warning-every: 5000
Given the data above, to what value do you recommend that we set
timeout-time
?
However long it takes you to reload aliases. Your current setup is fine, there's no real issue happening. Just the server freezing as it reloads aliases.
To be clear, you only need to change timeout-time if your server is crashing due to the freeze length.
Given the data above, to what value do you recommend that we set
timeout-time
?However long it takes you to reload aliases. Your current setup is fine, there's no real issue happening. Just the server freezing as it reloads aliases.
So 15000 (ms) ? The default is 240 !
Given the data above, to what value do you recommend that we set
timeout-time
?However long it takes you to reload aliases. Your current setup is fine, there's no real issue happening. Just the server freezing as it reloads aliases.
So 15000 (ms) ? The default is 240 !
Timeout time is in seconds, not milliseconds. 240 is fine (default is actually 60, to my knowledge).
Then that is not working. It's been set to 240 since I don't know when. Per the above, the reload is taking 15 seconds.