Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-33084

Aggregate with explain >= 'executionStats' attempts to serialize a disposed pipeline

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.7.2
    • Component/s: Aggregation Framework
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL
    • Sprint:
      Query 2018-02-12
    • Linked BF Score:
      0

      Description

      The simplest repro is running the following agg explain:

      coll.explain('executionStats').aggregate([{$project: {_id: 1}}, {$sort: {_id: 1}}]);
      

      This will trigger an access violation when the explain path attempts to serialize the pipeline after executing the plan, which was disposed by the DocumentSourceSort stage. In the case above, the projection stage releases a unique_ptr when it's disposed, however that same pointer is de-referenced in its serialize method.

        Attachments

          Activity

            People

            Assignee:
            nicholas.zolnierz Nicholas Zolnierz
            Reporter:
            nicholas.zolnierz Nicholas Zolnierz
            Participants:
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: