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

Rename misleading functions and structs in cluster_aggregate.cpp

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 3.6.0-rc2
    • Affects Version/s: None
    • Component/s: Querying
    • None
    • Fully Compatible
    • Query 2017-11-13

      • The function currently named 'establishShardCursors' is responsible for targeting and splitting/reassembling the pipeline. It does not actually establish any cursors itself; if we are running an aggregation, it delegates to the method currently called 'establishShardCursorsWithoutRetrying', and if we are running an explain then we don't attempt to establish any cursors at all.
      • The struct currently called 'EstablishShardCursorsResults' again may or may not actually contain any cursors on return, but will always contain the results of the pipeline targeting. In fact, the variable that currently stores the returned struct in runAggregate is the much more aptly named 'targetingResults'.

      Both of these should be renamed to provide a more accurate description of their purpose.

            Assignee:
            bernard.gorman@mongodb.com Bernard Gorman
            Reporter:
            bernard.gorman@mongodb.com Bernard Gorman
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: