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

Remove unused "JS" mode from JSON output options

    XMLWordPrintableJSON

Details

    • Fully Compatible
    • Platforms 2017-01-23

    Description

      From https://github.com/mongodb/mongo/blob/r3.3.9/src/mongo/bson/oid.h#L238

      We have 3 modes, "JS", "10gen", and "Strict".

      • "JS" is Javascript JSON compatible
      • "10gen" is Shell parseable
      • "Strict" is strict RFC compliant JSON

      "JS" is distinguished from "Strict" only by having a Date constructor.

      However, as documented in http://docs.mongodb.org/manual/reference/mongodb-extended-json/ and confirmed by removing the option and compiling, the "JS" mode is not used anywhere in the server. The correct answer may not be to take this out now, but this should make it clear that backwards compatibility doesn't need to be preserved for any of this dead code if this system is ever refactored.

      Attachments

        Activity

          People

            jonathan.reams@mongodb.com Jonathan Reams
            sverch Shaun Verch
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: