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

dropDatabase may log a confusing number of collection drops

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major - P3 Major - P3
    • 4.1.7
    • None
    • Logging, Storage
    • None
    • Fully Compatible
    • ALL
    • v4.0, v3.6
    • Hide

      Observed on 3.6.5 on macOS

      db.foo.insert({})
      db.dropDatabase()
      

      In the logs:

      2018-06-27T06:38:26.738-0400 I COMMAND  [conn6] dropDatabase test - starting
      2018-06-27T06:38:26.738-0400 I COMMAND  [conn6] dropDatabase test - dropping 0 collections
      2018-06-27T06:38:26.768-0400 I COMMAND  [conn6] dropDatabase test - finished
      

      Show
      Observed on 3.6.5 on macOS db.foo.insert({}) db.dropDatabase() In the logs: 2018-06-27T06:38:26.738-0400 I COMMAND [conn6] dropDatabase test - starting 2018-06-27T06:38:26.738-0400 I COMMAND [conn6] dropDatabase test - dropping 0 collections 2018-06-27T06:38:26.768-0400 I COMMAND [conn6] dropDatabase test - finished
    • Storage NYC 2018-12-31, Storage NYC 2019-01-14

    Description

      I believe that if a collection is dropped very quickly as part of dropDatabase, we do not count it in the dropDatabase command. This can confuse some users since we may log that no collections were dropped. We could either make this number always accurate or clarify what metric it is tracking.

      Attachments

        Activity

          People

            gregory.wlodarek@mongodb.com Gregory Wlodarek
            kelsey.schubert@mongodb.com Kelsey Schubert
            Votes:
            0 Vote for this issue
            Watchers:
            10 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: