if (isLeader()) {
if (isLeader(thisAgent)) { logger.info("Expired Status:" + " agent=" + name + " state=RESTART");
    public void expired(String name) {      if (isLeader()) {        newState(name, FAILED_RESTART);      }    }