-
Type: Improvement
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
Labels:
-
Cluster Scalability
We have a lot of similar code for performing a no-op write:
- _performNoopWrite
- resharding::doNoopWrite
- no-op write in session catalog
- migration util no-op write, (and another)
- refine collection no-op write
- resharding coordinator no-op write
- resharding donor service’s generateMinFetchTimestamp does a no-op write
- TransactionParticipant::performNoopWrite
- tenant_migration_access_blocker::performNoopWrite
- NoopWriter does a no-op write the same way
On initial inspection it seems like almost all of these cases could be replaced with a call to resharding::doNoopWrite. I'm not sure what the distinction between onOpMessage and onInternalOpMessage is. Also, some of these callers wrap the operation in a DBLock which does not appear to be required in all cases.
We should decide on a single helper for this, and reuse that helper where possible in the above linked locations.