Get rid of old BSON APIs with few users and better replacements

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Fixed
    • Priority: Major - P3
    • 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Server Programmability
    • Fully Compatible
    • Programmability 2024-11-11, Programmability 2024-11-25
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      We should scrub out the remaining few users of the following APIs so that they can be removed:

      • BSONForEach — Replace with range-for loop
      • BSONObjIterator::moreWithEoo() — Use more() and remove if (e.eoo()) break;. Consider rewriting to use range-for loop.
      • BSONObj::getObjectId — Use if (auto id = obj["_id"]; id) {...}
      • BSONObj::removeFields(std::set<std::string>) — Use the StringDataSet overload instead.

              Assignee:
              Adithi Raghavan
              Reporter:
              Mathias Stearn
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: