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

Reduce contention on ShardingState::_mutex for insert workloads

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 3.6.0-rc3
    • Component/s: Sharding
    • None
    • ALL

      Currently, each write that's part of a batch performs two separate checks for shard version. Once at the beginning of the batch and a second time when the write has been written to the oplog.

      Performing these checks causes a hot mutex to be acquired in order to retrieve the sharding state for the collection, so the first one should ideally be removed.

            Assignee:
            kaloian.manassiev@mongodb.com Kaloian Manassiev
            Reporter:
            kaloian.manassiev@mongodb.com Kaloian Manassiev
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: