MR cluster command does not validate collection namespace

XMLWordPrintableJSON

    • Fully Compatible
    • ALL
    • Hide

      On mongos, run mapReduce on an invalid collection name.

       

      db.runCommand({ 
         mapReduce: /test/, 
         map: map, 
         reduce: reduce, 
         out: {inline: 1}
      });
      

       

       

      Show
      On mongos, run mapReduce on an invalid collection name.   db.runCommand({ mapReduce: /test/, map: map, reduce: reduce, out: {inline: 1} });    
    • Query 2019-07-15, Query 2019-07-29
    • 19
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      A refactor for the cluster mapReduce by SERVER-41938 fails to validate the collection namespace on sharded clusters, which must be a string. Specifically the previous implementation uses parseNsCollectionRequired while the recent change uses parseNsFromCommand which skips some validations.

              Assignee:
              Xin Hao Zhang (Inactive)
              Reporter:
              Xin Hao Zhang (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: