@Override
    public void messageReceived(IoSession session, Object message) throws Exception {
        if(message instanceof Message){
            System.out.println(((Message) message).getBody());
        } else{
            System.out.println("Unknown message type received: " + message.getClass().toString());
        }
    }