-
Type:
Task
-
Resolution: Fixed
-
Priority:
Major - P3
-
Affects Version/s: None
-
Component/s: Replication
-
Replication
-
Fully Compatible
-
Repl 2026-09-14, Repl 2026-09-28
-
None
-
None
-
None
-
None
-
None
-
None
-
None
*This summary was written by AI and I do not endorse it: *
Summary
Wire retry-delay recording at the findAndModify retry-detection call site for SERVER-107365 (retried writes latency histogram).
Site
src/mongo/db/commands/query_cmd/find_and_modify.cpp (~L471-475)
The retry branch already has the OplogEntry in hand, so compute
millis = Date_t::now() - entry->getWallClockTime()
and call
RetryableWritesStats::get(opCtx)->recordRetriedWriteDelay(millis)
alongside the existing incrementRetriedStatementsCount().
Test
Add one test asserting a retried findAndModify lands one sample in the expected bucket (SERVER-107365 Task 3: one test per call site).
References
- SERVER-107365 (Add Metrics for Retried Writes)
- Prereqs:
SERVER-134421(metric definition),SERVER-134422(record helper)
- is related to
-
SERVER-134421 Add metric definition for retryable write latency metric
-
- Closed
-
-
SERVER-134422 Add utility function for recording retryable write latency
-
- Closed
-