From e1b901c4c6129afd133c9364c4996e61b03ab618 Mon Sep 17 00:00:00 2001 From: vemacs Date: Wed, 23 Nov 2016 12:54:56 -0500 Subject: [PATCH] Optimize Network Queue diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java index 94df23c31f..c97953a2fd 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -118,7 +118,7 @@ public abstract class MinecraftServer implements IAsyncTaskHandler, IMojangStati private final GameProfileRepository W; private final UserCache X; private long Y; - protected final Queue> g = Queues.newConcurrentLinkedQueue(); + protected final Queue> g = new com.destroystokyo.paper.utils.CachedSizeConcurrentLinkedQueue<>(); // Spigot, PAIL: Rename // Paper - Make size() constant-time private Thread serverThread; private long aa = SystemUtils.b(); private final IReloadableResourceManager ac; -- 2.18.0