Make CanonicalQuery::canonicalize() throw exceptions rather than return non-OK statuses

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Won't Fix
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Optimization
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      This was considered as part of SERVER-76042. It would simplify most of the call sites who just 'uassertStatusOK()' anyway, and will also simplify some of the implementation. It also allows the linked follow-up ticket.

      Warning: I attempted this and the patch got quite large. It is conceptually simple though and there wasn't anything that came up that seemed super risky. There were a couple try/catches to preserve behavior in an "if not OK" branch, but I recall it was exclusively error message context, and perhaps breaking a retry cycle in one place.

              Assignee:
              [DO NOT USE] Backlog - Query Optimization
              Reporter:
              Charlie Swanson
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: