Class OverseerCollectionMessageHandler

    • Method Detail

      • getTimerName

        public String getTimerName​(String operation)
        Specified by:
        getTimerName in interface OverseerMessageHandler
        Parameters:
        operation - the operation to be timed
        Returns:
        the name of the timer to use for the operation
      • getTaskKey

        public String getTaskKey​(org.apache.solr.common.cloud.ZkNodeProps message)
        Specified by:
        getTaskKey in interface OverseerMessageHandler
        Parameters:
        message - the message being processed
        Returns:
        the taskKey for the message for handling task exclusivity
      • lockTask

        public OverseerMessageHandler.Lock lockTask​(org.apache.solr.common.cloud.ZkNodeProps message,
                                                    long batchSessionId)
        Grabs an exclusive lock for this particular task.
        Specified by:
        lockTask in interface OverseerMessageHandler
        Returns:
        null if locking is not possible. When locking is not possible, it will remain impossible for the passed value of batchSessionId. This is to guarantee tasks are executed in queue order (and a later task is not run earlier than its turn just because it happens that a lock got released).
      • isClosed

        public boolean isClosed()
        Specified by:
        isClosed in interface org.apache.solr.common.SolrCloseable