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

Optimize TicketHolder::waitForTicketUntil()

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Major - P3 Major - P3
    • 4.7.0
    • None
    • Concurrency
    • None
    • Fully Compatible
    • Query 2020-03-09, Query 2020-03-23

    Description

      This function blocks on a semaphore until a timeout is reached. In the case that we are not contending with other threads to acquire the semaphore, this function need not read the clock in order to calculate its deadline. Reading the clock can be expensive, so it would be beneficial to avoid this work in the common case.

      This function is worth optimizing, since it's on the hot path for acquiring a global lock, which pretty much all database operations need to do.

      Attachments

        Activity

          People

            david.storch@mongodb.com David Storch
            david.storch@mongodb.com David Storch
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: