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

ephemeralForTest cursors need to be made thread_safe

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Works as Designed
    • Icon: Major - P3 Major - P3
    • None
    • None
    • Storage
    • None
    • ALL
    • Execution Team 2019-11-04
    • 14

    Description

      The EphemeralForTestRecordStore uses a mutex to control access to its _data->records member. However, EphemeralForTestRecordStore::Cursor and ::ReverseCursor get a direct reference to this member and do not lock the mutex when accessing it.

      Furthermore, these classes cache an iterator to the structure, which is a std::map; in the case of a rollback these iterators will be invalid, and in the case of a delete they might be.

      Attachments

        Activity

          People

            milkie@mongodb.com Eric Milkie
            matthew.russotto@mongodb.com Matthew Russotto
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: