Create CanonicalQuery without mutating source pipeline

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Optimization
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      createCanonicalQuery currently modifies its source pipeline before it creates a CanonicalQuery, so in case of a failure we can end up with a modified pipeline. This is fine in cases when failure of creating a CanonicalQuery object means failure of the query. However, in case of the join optimizer it only means that we should bail out from creating JoinGraph. To work around this issue we create a $lookup stage in the join optimizer when we try to create a CQ from it, we should consider if can avoid creating this copy.

            Assignee:
            Unassigned
            Reporter:
            Alexander Ignatyev
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated: