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

Merge DocumentSourceGroup::MemoryUsageTracker with GroupStats

    • ALL
    • Query 2020-12-14, Query 2021-01-11

      We have nested structure called MemoryUsageTracker inside DocumentSourceGroup, which tracks memory related statistics. 

      Ticket 48380 introduced GroupStats in the file src/mongo/db/exec/plan_stats.h

      While working on this CR, I moved 2 fields from MemoryUsageTracker, namely, memoryUsageBytes and usedDisk to GroupStats. 

      I did not moved all the fields of MemoryUsageTracker to GroupStats taking into consideration that exposing all fields might not be required.

      But, having 2 separate structure to track the stats of DocumentSourceGroup is also not legible.

       

      As part of this ticket, we should attempt to revisit MemoryUsageTracker's stats and see if we can move more field to the GroupStats. And if possible, get rid of MemoryUsageTracker all together.

       

      Commit details for your reference: https://github.com/mongodb/mongo/commit/62a3ca9041393dca40273ff935677c686cfa7fbb 

       

       

            Assignee:
            rishab.joshi@mongodb.com Rishab Joshi (Inactive)
            Reporter:
            rishab.joshi@mongodb.com Rishab Joshi (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: