Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-93871

Add unit test coverage for Index Builds code

    • Type: Icon: Task Task
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • Storage Execution
    • Execution Team 2024-10-14

      There are a number of index build-related files that are lacking good unit coverage. This ticket will look into adding more unit coverage where possible/appropriate. More information on the existing coverage files can be found by following this guide. Some files of interest include:

      mongo/db/catalog/index_builds_manager.cpp

      mongo/db/index_builds_coordinator.cpp

      mongo/db/repl_index_build_state.cpp

      mongo/db/index_builds_coordinator_mongod.cpp

      mongo/db/active_index_builds.cpp

      mongo/db/index/index_build_interceptor.cpp

      mongo/db/catalog/index_build_oplog_entry.cpp

      mongo/db/index_build_entry_helpers.cpp

       

      Failpoints to look at:

      hangBeforeGettingIndexBuildEntry
      hangAfterAcquiringIndexBuildSlot
      hangAfterRegisteringIndexBuild
      hangBeforeInitializingIndexBuild
      hangIndexBuildAfterSignalPrimaryForCommitReadiness
      hangBeforeRunningIndexBuild
      hangIndexBuildBeforeSignalingPrimaryForAbort
      hangIndexBuildBeforeTransitioningReplStateTokAwaitPrimaryAbort
      hangBeforeVoteCommitIndexBuild
      hangAfterIndexBuildFirstDrain
      hangAfterIndexBuildSecondDrain
      hangAfterIndexBuildDumpsInsertsFromBulk
      hangAfterIndexBuildDumpsInsertsFromBulkLock
      hangAfterInitializingIndexBuild
      hangBeforeCompletingAbort
      failIndexBuildOnCommit
      hangIndexBuildBeforeAbortCleanUp
      hangIndexBuildOnStepUp
      hangAfterSettingUpResumableIndexBuild
      hangIndexBuildBeforeCommit
      hangBeforeBuildingIndex
      hangBeforeBuildingIndexSecond
      hangIndexBuildBeforeWaitingUntilMajorityOpTime
      hangBeforeUnregisteringAfterCommit
      failSetUpResumeIndexBuild
      failIndexBuildWithError
      failIndexBuildWithErrorInSecondDrain
      hangInRemoveIndexBuildEntryAfterCommitOrAbort
      hangIndexBuildOnSetupBeforeTakingLocks
      hangAbortIndexBuildByBuildUUIDAfterLocks
      hangOnStepUpAsyncTaskBeforeCheckingCommitQuorum
      hangDuringIndexBuildDrainYield
      hangDuringIndexBuildDrainYieldSecond
      hangIndexBuildDuringDrainWritesPhase
      hangIndexBuildDuringDrainWritesPhaseSecond
      constrainMemoryForBulkBuild
      hangAfterSettingUpIndexBuild
      hangAfterSettingUpIndexBuildUnlocked
      hangAfterStartingIndexBuild
      hangAfterStartingIndexBuildUnlocked
      hangIndexBuildDuringCollectionScanPhaseBeforeInsertion
      hangIndexBuildDuringCollectionScanPhaseAfterInsertion
      leaveIndexBuildUnfinishedForShutdown
      fixedCursorDataSizeOf512KBForDataThrottle
      fixedCursorDataSizeOf2MBForDataThrottle
      failRecordStoreTraversal
      hangDuringValidationInitialization
      createIndexesWriteConflict
      hangBeforeCreateIndexesCollectionCreate
      hangBeforeIndexBuildAbortOnInterrupt
      hangAfterIndexBuildAbort
      hangCreateIndexesBeforeStartingIndexBuild
      hangIndexBuildDuringBulkLoadPhase
      hangIndexBuildDuringBulkLoadPhaseSecond
      hangDuringIndexBuildBulkLoadYield
      hangDuringIndexBuildBulkLoadYieldSecond

       

            Assignee:
            Unassigned Unassigned
            Reporter:
            damian.wasilewicz@mongodb.com Damian Wasilewicz
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: