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

Don't remove({}) large collections in batch_write_command_insert.js

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 4.7.0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Fully Compatible
    • ALL
    • Repl 2020-07-13, Repl 2020-07-27, Repl 2020-08-10
    • 15

      In batch_write_command_insert.js, we use remove({}) to get a collection back to its initial empty state. If the collection has a lot of elements in it (and we do at one point), then we end up deleting them all one by one on the secondaries, which puts a lot of load on the test infrastructure and causes spurious failures. We should drop the collection rather than remove({}) unless there's a good reason to do otherwise. It appears the remove({}) has been there since the test was created.

            Assignee:
            matthew.russotto@mongodb.com Matthew Russotto
            Reporter:
            matthew.russotto@mongodb.com Matthew Russotto
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: