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

Use hazard pointers for reading replica-set configuration

    • Type: Icon: Improvement Improvement
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Internal Code
    • None
    • Service Arch

      Make the _rsConfig in ReplicationCoordinatorImpl hazard pointer protected. There are a ton of methods that just lock the (very hot) _mutex just to read the config, and unlock before acting on it. Given that callers are already OK with accepting stale returns (otherwise they would need to hold the mutex themselves) it should be safe. Examples include but are not limited to all of these.

            Assignee:
            Unassigned Unassigned
            Reporter:
            amirsaman.memaripour@mongodb.com Amirsaman Memaripour
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: