[SERVER-46734] Disable the index state transition check . Created: 09/Mar/20  Updated: 29/Oct/23  Resolved: 10/Mar/20

Status: Closed
Project: Core Server
Component/s: Storage
Affects Version/s: 4.5 Required, 4.4.0
Fix Version/s: 4.4.0-rc0, 4.7.0

Type: Bug Priority: Major - P3
Reporter: Suganthi Mani Assignee: Suganthi Mani
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Related
related to SERVER-46560 Make Abort index build logic determin... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v4.4
Sprint: Execution Team 2020-03-23
Participants:
Linked BF Score: 47

 Description   

Disable the index state transition check as aborting index build logic is currently not deterministic. By disabling the index state transition check, we are preserving the old behavior that was present before commit quorum.

P.S: This check should be reenabled once SERVER-46560 is done.



 Comments   
Comment by Githook User [ 11/Mar/20 ]

Author:

{'name': 'Suganthi Mani', 'username': 'smani87', 'email': 'suganthi.mani@mongodb.com'}

Message: SERVER-46734 Disable the index state transition check.

(cherry picked from commit 83b4367daba1395aaf09f157db7edff3b2fd7431)
Branch: v4.4
https://github.com/mongodb/mongo/commit/cf4ae58d0f754a263ec73ff19f676a614801beb9

Comment by Githook User [ 09/Mar/20 ]

Author:

{'name': 'Suganthi Mani', 'username': 'smani87', 'email': 'suganthi.mani@mongodb.com'}

Message: SERVER-46734 Disable the index state transition check.
Branch: master
https://github.com/mongodb/mongo/commit/83b4367daba1395aaf09f157db7edff3b2fd7431

Comment by Suganthi Mani [ 09/Mar/20 ]

code review url: https://mongodbcr.appspot.com/585950015/

Comment by Suganthi Mani [ 09/Mar/20 ]

I have 3 quick hacks

1) When we reset the promise future pair, we can reset the states set in in indexBuildManager and replIndexBuildState. This doesn't fix the problem of old primary index build that getting aborted during collection scanning or draining phase. And, then old primary receives an abortIndexBuild oplog entry and tries to set the state 'kPrepareAbort'.

2) I can disable the index state transition check, if we are trying to set the state with a value same as old value, but still we need to update the timestamp and abort reason.

3) Cleaner solution is to disable the check until SERVER-46560 is done.

Generated at Thu Feb 08 05:12:17 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.