Uploaded image for project: 'MongoDB Database Tools'
  1. MongoDB Database Tools
  2. TOOLS-185

mongoexport/import break BSONTimestamps

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • Legacy C++ Implementation
    • 2.8.0-rc0
    • mongoimport
    • None

    Description

      Somewhere between exporting and importing a Timestamp gets turned into a

      {"t": <time>, "i": <inc>}

      document.

      dgottlieb@keylime:~/10gen/mms/server$ mongo
      MongoDB shell version: 2.1.0
      connecting to: test
      > db.export.insert({t: Timestamp(0, 8)})
      > db.export.find()
      { "_id" : ObjectId("4f7f93e94057ae51e71576eb"), "t" : Timestamp(0, 8) }
      > 
      bye
      dgottlieb@keylime:~/10gen/mms/server$ mongoexport -d test -c export | mongoimport -d test -c import
      connected to: 127.0.0.1
      connected to: 127.0.0.1
      exported 1 records
      Fri Apr  6 21:10:17 imported 1 objects
      dgottlieb@keylime:~/10gen/mms/server$ mongo
      MongoDB shell version: 2.1.0
      connecting to: test
      > db.import.find()
      { "_id" : ObjectId("4f7f93e94057ae51e71576eb"), "t" : { "t" : 0, "i" : 8 } }
      > db.export.find()
      { "_id" : ObjectId("4f7f93e94057ae51e71576eb"), "t" : Timestamp(0, 8) }

      Attachments

        Issue Links

          Activity

            People

              mikeo@mongodb.com Michael O'Brien
              daniel.gottlieb@mongodb.com Daniel Gottlieb
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: