Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-53842

[BP to 7.0.5] Use streamId instead of index.Stream to determine stream catchup pending

    XMLWordPrintable

Details

    • Untriaged
    • 1
    • Unknown

    Description

      In indexer::checkCatchupPendingForStream, indexer should check the keyspaceId for the stream that is passed through and not the stream of the index. Otherwise, the index.Defn.KeyspaceId(index.Stream) will fail and indexer will not start the MAINT_STREAM

      func (idx *indexer) checkCatchupPendingForStream(streamId common.StreamId,
      	keyspaceId string) bool {
       
      	//catch is only possible for MAINT_STREAM
      	if streamId != common.MAINT_STREAM {
      		return false
      	}
       
      	//check if any index of the given keyspaceId is in the Stream
      	for _, index := range idx.indexInstMap {
       
      		if index.Defn.KeyspaceId(index.Stream) == keyspaceId && index.Stream == common.INIT_STREAM &&
      			index.State == common.INDEX_STATE_CATCHUP {
      			return true
      		}
      	}
       
      	return false
      }
      

       

      Attachments

        For Gerrit Dashboard: MB-53842
        # Subject Branch Project Status CR V

        Activity

          People

            hemant.rajput Hemant Rajput
            varun.velamuri Varun Velamuri
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty