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

Yield policy for batch-inserts should be the same as for batch-updates/deletes

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: 2.6.0-rc3
    • Fix Version/s: 2.6.1, 2.7.0
    • Component/s: Write Ops
    • Labels:
    • Operating System:
      ALL
    • Backport Completed:

      Description

      Issue Status as of April 16, 2014

      ISSUE SUMMARY
      Batch inserts can potentially yield after each single insert. This can negatively impact performance and is inconsistent with the yield policy of batch updates and deletes, which check less frequently.

      USER IMPACT
      Bulk insert tasks have a noticeable performance penalty compared to previous versions of MongoDB.

      WORKAROUNDS
      An older version of the driver that does not use the write commands is unaffected by this issue and can be used as a workaround with MongoDB 2.6.0.

      RESOLUTION
      Changing the yielding policy to the same as updates/deletes (allow yields less frequently) improves insert performance significantly (by ~28% in internal tests).

      AFFECTED VERSIONS
      Version 2.6.0 is affected by this bug.

      PATCHES
      The patch is included in the 2.6.1 production release.

      Original description

      For batch inserts, we were checking to yield after each insert. Batch updates/deletes only check every 100 operations, so batch inserts should be changed to match.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: