BasicDBObject.toString() returns STRICT extended JSON, expecting RELAXED

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Works as Designed
    • Priority: Unknown
    • None
    • Affects Version/s: 3.7.0, 3.12.0
    • Component/s: BSON, JSON
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Older versions (pre-3.7) of the driver when calling BasicDBObject.toString() returns simple JSON output, i.e

      {
         "name""foo", 
         "age" : 10}
      

      New versions (3.7 to 3.12), when calling the BasicDBObject.toString() method returns STRICT extended json: i.e

      {
         "name" :  "foo", 
         "age" : {"$numberLong": 10"}
      }
      

      Would it is possible to override the default behavior by some flag instead of using the BasicDBObject.toJson(JsonWriterSettings). Some applications rely on the prior behavior to feed other libraries that doesn't expect extended json.
       

              Assignee:
              Unassigned
              Reporter:
              Adamo Tonete (Inactive)
              None
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: