WorldEdit

WorldEdit

43M Downloads

ConcurrentModificationException

LadyCailinBot opened this issue ยท 5 comments

commented

WORLDEDIT-2569 - Reported by cptwin

Getting this over and over again in the crash log. Server crashes every 10-50 minutes:

Description: Exception in server tick loop
java.util.ConcurrentModificationException
at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:819)
at java.util.ArrayList$Itr.next(ArrayList.java:791)
at net.minecraft.server.v1_4_6.EntityTrackerEntry.track(EntityTrackerEntry.java:85)
at net.minecraft.server.v1_4_6.EntityTracker.updatePlayers(EntityTracker.java:138)
at net.minecraft.server.v1_4_6.MinecraftServer.r(MinecraftServer.java:589)
at net.minecraft.server.v1_4_6.DedicatedServer.r(DedicatedServer.java:224)
at net.minecraft.server.v1_4_6.MinecraftServer.q(MinecraftServer.java:494)
at net.minecraft.server.v1_4_6.MinecraftServer.run(MinecraftServer.java:427)
at net.minecraft.server.v1_4_6.ThreadServerApplication.run(SourceFile:849)
Recent tasks from 21142-21172{WorldEdit:com.sk89q.worldedit.bukkit.SessionTimer@21149,}

Something is happening with the SessionTimer, our server is using the latest WorldEdit dev for 1.4.6
https://github.com/sk89q/worldedit/blob/master/src/main/java/com/sk89q/worldedit/bukkit/SessionTimer.java

I'd be really keen to help out but I don't quite understand what the session timer is used for.

commented

Comment by wizjany

can you provide more info? full stack trace, server info, etc

commented
commented

Comment by wizjany

believe we established this is not caused by WE

commented

Comment by cptwin

Just found the problem piece of code:
public void flushExpiredSessions(SessionCheck checker)
in https://github.com/sk89q/worldedit/blob/master/src/main/java/com/sk89q/worldedit/WorldEdit.java

Iterating over players to check if they are online, if any other plugin kicks/removes the player from the server while this is iterating it will break.
It also explains the sporaticness of it as it is hard to reproduce!

Sorry for the questions, but can the plugin not just check for players online when they perform a command? What other times would you need to do this check?

commented

Comment by 10019872

I have had this problem as well, anyway you guys can fix this?