Review error handling

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Incomplete
    • Priority: Minor - P4
    • None
    • Affects Version/s: Backlog
    • Component/s: Usability
    • None
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      This case is intentionally vague. The basic point is that we should go through every mechanism where an error is returned to the client and try to make that error reporting as uniform as possible. Here's one example (but there are certainly more). A failed group will get picked up by a following getLastError:

      > db.runCommand({group: {$keyf: "5 ++ 5", $reduce: "", ns: "test", cond: {}, initial: {}}});

      { "errmsg" : "exception: reduce setup exec failed", "code" : 10228, "ok" : 0 } > db.runCommand("getLastError"); { "err" : "reduce setup exec failed", "code" : 10228, "n" : 0, "ok" : 1 }

      A failed M/R won't:

      > db.runCommand(

      {mapReduce: "test", map: "5 ++ 5", reduce: ""}

      );

      { "assertion" : "map compile failed: JS Error: SyntaxError: syntax error reduce setup:0", "assertionCode" : 9012, "errmsg" : "db assertion failure", "ok" : 0 } > db.runCommand("getLastError"); { "err" : null, "n" : 0, "ok" : 1 }

      Please add comments w/ any additional specific inconsistencies.

            Assignee:
            Unassigned
            Reporter:
            Michael Dirolf (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: