@Override
    public void process(DistributionMessage msg) {
      if (logger.isDebugEnabled()) {
        logger.debug("shutdownAll reply processor is processing {}", msg);
      }
      if (msg instanceof ShutdownAllResponse) {
        if (((ShutdownAllResponse) msg).isToShutDown()) {
          synchronized (results) {
            logger.debug("{} adding {} to result set {}", this, msg.getSender(),
                results);
            results.add(msg.getSender());
          }
        } else {
          // for member without cache, we will not wait for its result
          // so no need to wait its DS to close either
          removeMember(msg.getSender(), false);
        }

        if (msg.getSender().equals(dmgr.getDistributionManagerId())) {
          // mark myself as done since my response has been sent and my DS
          // will be closed later anyway
          removeMember(msg.getSender(), false);
        }
      }

      if (msg instanceof ReplyMessage) {
        ReplyException ex = ((ReplyMessage) msg).getException();
        if (ex != null) {
          processException(msg, ex);
        }
      }

      checkIfDone();
    }
If response arrives, we will save into results and keep wait for member's departure. If the
member is departed before sent response, no wait for its response
geode-core/src/main/java/org/apache/geode/internal/admin/remote/ShutdownAllRequest.java