Details
-
Bug
-
Resolution: Fixed
-
Minor
-
7.6.0, 7.0.0, 7.0.1, 7.0.2, 7.0.3, 7.0.4, 7.1.4, 7.0.5, 7.1.0, 7.1.1, 7.1.2, 7.2.0, 7.1.3, 7.2.1, 7.1.5, 7.2.4, 7.0.6, 7.1.7, 7.2.2, 7.1.6, 7.2.3, 7.2.5, 7.6.2, 7.2.6, 7.6.1, 7.6.4, 7.2.7
-
None
-
Untriaged
-
0
-
Unknown
Description
Currently minor as no bad side-effect has been identified...
Whilst unit-testing for an issue that is suspected to be related to an ActiveStream against a rolled-back vbucket, it is possible that the ActiveStream (running on ActiveStreamCheckpointProcessorTask) can access the vbucket's checkpoint after the checkpoint was rolled back (CheckpointManager::clear has been called).
E.g.
- T1 is processing rollback and has just cleared the checkpoint manager
- T2 is ActiveStreamCheckpointProcessorTask and now executes nextCheckpointItemTask
A unit test exercising these steps show there is nothing stopping the stream from calling vb.checkpointManager->getNextItemsForCursor which has now been cleared by the rollback. The unit test though shows that only a checkpoint_start item is returned and the stream will not update lastReadSeqno.
The rollback code itself shows that DCP streams should be ended when rollback occurs, but this happens at the end of the rollback processing.
This really should be moved to be one of the first things we do when rolling back, preventing the stream accessing the vbucket objects as the rollback is processed.
Attachments
For Gerrit Dashboard: MB-62840 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
213097,2 | MB-62840: Remove DCP streams before rollback processing | master | kv_engine | Status: MERGED | +2 | +1 |