Query execution stats tree unnecessarily serialized to BSON if find() query generates log line

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Duplicate
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Performance, Querying
    • None
    • ALL
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      runQuery() makes a call to getStats() (which generates the stats tree as BSON) if the profiler is enabled /or/ if the query will generate a log line. However, only the profiler consumes the stats tree. This means that getStats() is unnecessarily called if the query will generate a log line and the profiler is disabled (which is quite a common case, and getStats() is extraordinarily expensive).

            Assignee:
            David Storch
            Reporter:
            J Rassi (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: