mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 23:38:25 +01:00
Fix main thread priority being lowered (#9488)
This commit is contained in:
parent
975444e5d2
commit
49502449bb
1 changed files with 6 additions and 6 deletions
|
@ -83,10 +83,10 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||||
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
|
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||||
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
|
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||||
@@ -0,0 +0,0 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
@@ -0,0 +0,0 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||||
S s0 = serverFactory.apply(thread); // CraftBukkit - decompile error
|
thread.setUncaughtExceptionHandler((thread1, throwable) -> {
|
||||||
|
MinecraftServer.LOGGER.error("Uncaught exception in server thread", throwable);
|
||||||
atomicreference.set(s0);
|
});
|
||||||
+ thread.setPriority(Thread.NORM_PRIORITY+2); // Paper - boost priority
|
+ thread.setPriority(Thread.NORM_PRIORITY+2); // Paper - boost priority
|
||||||
thread.start();
|
if (Runtime.getRuntime().availableProcessors() > 4) {
|
||||||
return s0;
|
thread.setPriority(8);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue