Don't lock MODE_X for compact() operation

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Duplicate
    • Priority: Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Storage
    • None
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Both RocksDB and WiredTiger (I think) can execute compact() operation concurrently with read and write requests. However, mongo currently locks an entire database with MODE_X when it compacts: https://github.com/mongodb/mongo/blob/master/src/mongo/db/commands/compact.cpp#L146

      Would it make sense to remove this?

              Assignee:
              Unassigned
              Reporter:
              Igor Canadi
              Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

                Created:
                Updated:
                Resolved: