Fixed that user expired sceduled job died without reporting causing error. Handling changed so that if an exception raises it does not prevent the server to check expired user next time. (Hope this will workaround the existing nasty problem in user handling and show the error causing code sequence).

This commit is contained in:
LevelX2 2014-04-25 14:57:45 +02:00
parent ec692902c7
commit 628cf2e018
3 changed files with 44 additions and 51 deletions

View file

@ -321,25 +321,19 @@ public class User {
}
public void kill(DisconnectReason reason) {
logger.debug("kill: game sessions " + gameSessions.size());
for (GameSession gameSession: gameSessions.values()) {
gameSession.kill();
}
logger.debug("kill: draft sessions " + draftSessions.size());
for (DraftSession draftSession: draftSessions.values()) {
draftSession.setKilled();
}
logger.debug("kill: tournament sessions " + tournamentSessions.size());
for (TournamentSession tournamentSession: tournamentSessions.values()) {
tournamentSession.setKilled();
}
logger.debug("kill: tables " + tables.size());
for (Entry<UUID, Table> entry: tables.entrySet()) {
TableManager.getInstance().leaveTable(userId, entry.getValue().getId());
}
logger.debug("kill: remove user from chat before");
ChatManager.getInstance().removeUser(userId, reason);
logger.debug("kill: remove user from chat after");
}
public void setUserData(UserData userData) {