Uploaded image for project: 'C# Driver'
  1. C# Driver
  2. CSHARP-1001

Fix certain output formats of JsonWriter

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 1.9.2
    • Affects Version/s: 1.9.1
    • Component/s: BSON
    • None
    • Minor Change

      JsonWriter output was designed a long time ago and is currently incompatible in a few minor ways with current versions of the server and the shell, as well as with mongoimport.

      In particular, the following needs to change:

      Strict output mode:
      
      BsonMaxKey: { $maxkey : 1 } => { $maxKey : 1 }
      BsonMinKey: { $minkey : 1 } => { $minKey : 1 }
      BsonTimestamp: { $timestamp : 64-bit-value } => { $timestamp : { t : 32-bit-value, i : 32-bit-value } }
      BsonUndefined: undefined => { $undefined : true }
      
      Shell output mode:
      
      BsonMaxKey: { $maxkey : 1 } => MaxKey
      BsonMinKey: { $minkey : 1 } => MinKey
      BsonTimestamp: { $timestamp : 64-bit-value } => Timestamp(32-bit-value, 32-bit-value)
      

            Assignee:
            robert@mongodb.com Robert Stam
            Reporter:
            robert@mongodb.com Robert Stam
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: