Uploaded image for project: 'MongoDB Shell'
  1. MongoDB Shell
  2. MONGOSH-1432

Create shell helpers for checkMetadataConsistency command

    • Type: Icon: Task Task
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 1.10.0
    • Affects Version/s: None
    • Component/s: None
    • None
    • 3
    • Not Needed
    • Iteration Brontosaurus, Iteration Citipati, Iteration Dreadnoughtus

      In PM-3020 we added a new command checkMetadataConsistency that returns a cursor.

      The command can be invoke at collection, database or cluster level and we should expose helpers for each level.

      • Collection:
        The command is invoked on "db" and the name of the collection is passed as command parameter
        db.coll.checkMetadataConsistency(optionalOptions = {})
        
      • Database:
        The command is invoked on "db" and command parameter is either empty string "" or 1
        db.checkMetadataConsistency(optionalOptions = {})
        
      • Cluster level
        The command is invoked on "admin" database and command parameter is either empty string "" or 1
        This level could be exposed either as sh function (I found this more intuitive):
        sh.checkClusterMetadataConsistency(optionaOptions = {})
        

        Or we can reuse the database helper and call it on the "admin" database:

        db.getSiblingDB('admin').checkMetadataConsistency(optionaOptions = {})
        

            Assignee:
            leroux.bodenstein@mongodb.com Le Roux Bodenstein
            Reporter:
            tommaso.tocci@mongodb.com Tommaso Tocci
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: