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

Checking if destined recipient has changed for resharding creates another full copy of the updated document

    XMLWordPrintableJSON

Details

    • Fully Compatible
    • ALL
    • Sharding 2020-11-30
    • 0

    Description

      mutablebson::Document::getObject() renders a full copy of the updated document. This can be expensive for larger documents. At minimum we should skip calling it when the collection isn't even sharded like UpdateStage::checkUpdateChangesShardKeyFields() does. Better would be to consolidate some the _doc.getObject() calls that UpdateStage::checkUpdateChangesShardKeyFields(), UpdateStage::wasReshardingKeyUpdated(), and updates which weren't performed in-place all do.

      Attachments

        Activity

          People

            max.hirschhorn@mongodb.com Max Hirschhorn
            max.hirschhorn@mongodb.com Max Hirschhorn
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: