-
Bug
-
Resolution: Invalid
-
Minor
-
Linux (Ubuntu 14.04)
-
ChestDrop
I have been stress texting my routine to find a random location and drop a chest with world border and towny integration (to stay inside world borders and outside town borders). I can complete 1000 chest drops with no trouble but I consistently crash the server with 10000 chest drops. It's always at the same stack, a RandomAccessFile read times out during nms.RegionFile.ChunkExists, stemming from CraftWorld.getChunkAt, sometimes called from CraftBlock.setBlockType, other times called directly in my plugin to ensure the chunk is loaded and generated before I spawn the chest. I also see frequent Stream Closed IOExceptions in RandomAccessFile.length() and RandomAccessFile.seek0().
I'm testing in a world with a 1000 block radius circle border, so I am hitting chunks in that range over and over again in a single thread. Testing smaller numbers, I still see the StreamClosed in 1000 sometimes, or 5000 frequently, but often not until 10000. I can drop 1000 chests 10 times, or 5000 chests twice, and no crash, only Stream Closed warnings, but when I drop 10000 I crash the server.