protected void startOrResumeMessageDispatcher(boolean sendMarkerDirectly) {
    // Only start or resume the dispatcher if it is Primary
    if (isPrimary) {
      // Add the marker to the queue
      EventID eventId = new EventID(_cache.getDistributedSystem());
      ClientMarkerMessageImpl clientMarkerMessage = new ClientMarkerMessageImpl(eventId);
      if (sendMarkerDirectly) {
        sendMessageDirectly(clientMarkerMessage);
      } else {
        _messageDispatcher.enqueueMarker(clientMarkerMessage);
      }

      // Set the message queue to primary.
      _messageDispatcher._messageQueue.setPrimary(true);

      // Start or resume the dispatcher
      synchronized (_messageDispatcher._pausedLock) {
        if (isPaused()) {
          // It is paused, resume it
          setPaused(false);
          if (_messageDispatcher.isStopped()) {
            if (logger.isDebugEnabled()) {
              logger.debug("{}: Starting dispatcher", this);
            }
            _messageDispatcher.start();
          } else {
            // ARB: Initialize transient fields.
            _messageDispatcher.initializeTransients();
            if (logger.isDebugEnabled()) {
              logger.debug("{}: Resuming dispatcher", this);
            }
            _messageDispatcher.resumeDispatching();
          }
        } else if (!_messageDispatcher.isAlive()) {
          if (logger.isDebugEnabled()) {
            logger.debug("{}: Starting dispatcher", this);
          }
          _messageDispatcher.start();
        }
      }
    }
  }
Initializes the message dispatcher thread. The <code>MessageDispatcher</code> processes the
message queue.
geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/CacheClientProxy.java