Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-12700

Docs for SERVER-40712: Clarify the behaviour of `db.dropDatabase` and the `dropDatabase` command

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.1.12
    • Component/s: manual, Server
    • Labels:
      None

      Description

      Description

      Description:

      For the 'mongo' shell documentation we need to make one change here: https://docs.mongodb.com/manual/reference/method/db.dropDatabase/#db.dropDatabase

      Right now the definition is 'db.dropDatabase(<option>)'. We should change this to clarify what <option> is, it can only be a write concern object. We should probably also link in documentation to what write concern is if users are visiting this page.

      Engineering Ticket Description:

      The drop database command and shell helper are both documented as accepting write concern, but reading through the code and testing them seems to disagree with the documentation.

      Specifically:

      • From the shell code it looks like db.dropDatabase does not allow any parameters. So how does one specify majority write concern through the shell helper?
      • Executing the dropDatabase command directly, without passing write concern seems to always result in a w:majority behaviour. In particular, Danny Hatcher performed these repro steps: "3 member replica set, fyncLocked 2 of the members, command hung on primary".

      I am filing this ticket to request clarification on the behaviour of the dropDatabase command and shell helper and to have the documentation updated.

      Scope of changes

      Impact to Other Docs

      MVP (Work and Date)

      Resources (Scope or Design Docs, Invision, etc.)

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              kay.kim Kay Kim (Inactive)
              Reporter:
              kay.kim Kay Kim (Inactive)
              Participants:
              Last commenter:
              Kay Kim Kay Kim (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Days since reply:
                1 year, 51 weeks ago
                Date of 1st Reply: