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

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

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

      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@mongodb.com David Storch
            Reporter:
            rassi J Rassi
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: