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

Include arrayFilters when estimating size of update command object on mongoS

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major - P3 Major - P3
    • 4.1.2
    • None
    • Sharding, Write Ops
    • None
    • Fully Compatible
    • ALL
    • Query 2018-07-30, Query 2018-08-13
    • 73

    Description

      In the mongoS write path here, we estimate the size of the update command that will be forwarded to the shards as follows:

      auto estSize = item.getUpdate().getQ().objsize() + item.getUpdate().getU().objsize() +
             collationSize + kEstUpdateOverheadBytes;
      

      We also dassert that estSize is greater than or equal to the size of the complete update command when the latter has been serialized to BSON. However, we don't include the size of the arrayFilters field in estSize, which means that debug builds with a large arrayFilters vector will terminate after failing this check.

      Attachments

        Activity

          People

            bernard.gorman@mongodb.com Bernard Gorman
            bernard.gorman@mongodb.com Bernard Gorman
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: