Uploaded image for project: 'Go Driver'
  1. Go Driver
  2. GODRIVER-1782

Aggregation with $out not always sent to primary

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.4.4
    • Component/s: None
    • Security Level: Public
    • Labels:
      None

      Description

      Based on the check here, the read preference should not be set for an aggregation that contains a $out (or $merge). However, when the pipeline is checked for a $out stage here, it does LookupErr("$out") on an array document that looks like this:

      {"0": {"$out": {"db": "test_db","coll": "test_dcoll"}}}
      

      So no top-level $out is found, and the readPref is being set, resulting in a potential error on $out.

        Attachments

          Activity

            People

            Assignee:
            isabella.siu Isabella Siu
            Reporter:
            daniel.ernst Daniel Ernst
            Participants:
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: