Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-88853

Check for lockFreeReads first in ReplicationCoordinatorImpl

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
    • Catalog and Routing
    • Fully Compatible
    • v8.0
    • CAR Team 2024-04-15

      Several methods in ReplicationCoordinatorImpl invariant on (isRSTLLocked() || isLockFreeReadsOp()). The first check is a bit more expensive since we take a spinlock and perform a map lookup, whereas the second just checks an int. We should swap around the checks.

            Assignee:
            daniel.gomezferro@mongodb.com Daniel Gomez Ferro
            Reporter:
            daniel.gomezferro@mongodb.com Daniel Gomez Ferro
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: