2019-11-06 20:03:47 +00:00
|
|
|
/**
|
|
|
|
|
* Tests different permutations of rolling-back index build start and commit oplog entries.
|
2025-08-28 14:15:08 -04:00
|
|
|
* @tags: [
|
2026-01-21 10:34:28 +01:00
|
|
|
* requires_mongobridge,
|
2026-01-28 12:01:07 -05:00
|
|
|
* requires_rollbacks,
|
2025-08-28 14:15:08 -04:00
|
|
|
* ]
|
2019-11-06 20:03:47 +00:00
|
|
|
*/
|
2023-08-02 13:01:31 +00:00
|
|
|
import {RollbackIndexBuildsTest} from "jstests/replsets/libs/rollback_index_builds_test.js";
|
2019-11-06 20:03:47 +00:00
|
|
|
|
|
|
|
|
const rollbackIndexTest = new RollbackIndexBuildsTest();
|
|
|
|
|
|
|
|
|
|
// Build a schedule of operations interleaving rollback and an index build.
|
|
|
|
|
const rollbackOps = ["holdStableTimestamp", "transitionToRollback"];
|
|
|
|
|
const indexBuildOps = ["start", "commit"];
|
|
|
|
|
|
|
|
|
|
// This generates 4 choose 2, or 6 schedules.
|
|
|
|
|
const schedules = RollbackIndexBuildsTest.makeSchedules(rollbackOps, indexBuildOps);
|
|
|
|
|
rollbackIndexTest.runSchedules(schedules);
|
|
|
|
|
rollbackIndexTest.stop();
|