Uploaded image for project: 'C Driver'
  1. C Driver
  2. CDRIVER-2606

mongoc_collection_watch pipeline argument should allow bson array

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 1.9.5, 1.10.0
    • Affects Version/s: None
    • Component/s: None
    • None

      ryan.timmons discovered that passing a bson array as the pipeline argument to mongoc_collection_watch silently fails to append anything and is the same as if no pipeline was passed.

      This is because the pipeline must be passed as a document like

      { "pipeline": [...] }
      

      This is partially consistent with the pipeline argument to mongoc_collection_aggregate, but mongoc_collection_aggregate also allows a bson array. mongoc_collection_watch should be consistent with the aggregate helper and allow either way to pass a pipeline.

            Assignee:
            kevin.albertson@mongodb.com Kevin Albertson
            Reporter:
            kevin.albertson@mongodb.com Kevin Albertson
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: