code: def _ZeroMQResponder(self, source_queue):
      
      if not self._closed_event or not self._terminate_event:
        raise RuntimeError('Missing closed or terminate event.')
  
      logger.debug('{0:s} responder thread started'.format(self.name))
  
      item = None
      while not self._terminate_event.is_set():
        if not item:
          try:
            if self._closed_event.is_set():
              item = source_queue.get_nowait()
            else:
              item = source_queue.get(True, self._buffer_timeout_seconds)
  
          except Queue.Empty:
            if self._closed_event.is_set():
              break
  
            continue
  
        try:
          # We need to receive a request before we can reply with the item.
          self._ReceiveItemOnActivity(self._zmq_socket)
  
        except errors.QueueEmpty:
          if self._closed_event.is_set() and self._queue.empty():
            break
  
          continue
  
        sent_successfully = self._SendItem(self._zmq_socket, item)
        item = None
        if not sent_successfully:
          logger.error('Queue {0:s} unable to send item.'.format(self.name))
          break
  
      logger.info('Queue {0:s} responder exiting.'.format(self.name))
      self._zmq_socket.close(self._linger_seconds)
docs: Listens for requests and replies to clients.
  
      Args:
        source_queue (Queue.queue): queue to use to pull items from.
  
      Raises:
        RuntimeError: if closed or terminate event is missing.