* Set the game thread name to the game id.

This commit is contained in:
LevelX2 2015-02-12 13:51:27 +01:00
parent ef147bc80c
commit 38f9bb90b2

View file

@ -38,7 +38,7 @@ import org.apache.log4j.Logger;
*
* @author BetaSteward_at_googlemail.com
*/
public class GameWorker implements Callable {
public class GameWorker<T> implements Callable {
private static final Logger logger = Logger.getLogger(GameWorker.class);
@ -56,6 +56,7 @@ public class GameWorker implements Callable {
public Object call() {
try {
logger.debug("GAME WORKER started gameId "+ game.getId());
Thread.currentThread().setName("GAME " + game.getId());
game.start(choosingPlayerId);
game.fireUpdatePlayersEvent();
gameController.gameResult(game.getWinner());