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

$sample with explain(true) hangs

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 3.6.7
    • Affects Version/s: 3.6.0
    • Component/s: Aggregation Framework
    • None
    • Fully Compatible
    • ALL
    • Hide
      db.c.drop()
      for (i = 0; i < 1000; i++ ) { db.c.insertOne({size:1})}
      db.c.explain(true).aggregate({$sample: {size: 10}})
      
      Show
      db.c.drop() for (i = 0; i < 1000; i++ ) { db.c.insertOne({size:1})} db.c.explain(true).aggregate({$sample: {size: 10}})
    • Query 2018-07-16, Query 2018-07-30, Query 2018-08-13

      Observed in v3.6. Unable to reproduce on v3.4.

      $sample command never returns when run with explain(true). db.currentOps() shows:

         "planSummary":  "MULTI_ITERATOR",

         "numYields": 18619890,

      numYields continuously increases.

            Assignee:
            ian.boros@mongodb.com Ian Boros
            Reporter:
            josef.ahmad@mongodb.com Josef Ahmad
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: