Mongo export throws reflect.Value.Type errors

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Critical - P2
    • 3.0.7, 3.1.9
    • Affects Version/s: 3.0.6
    • Component/s: mongoexport
    • None
    • Server Tools A (10/09/15)
    • v3.0

      We upgraded our mongo instance from 3.0.4 -> 3.0.6. Mongoexport has been working fine from 2.x, 3.0.x, but started breaking as soon as we upgraded to 3.0.6.

      It seems like types are being handled funky since this commit was introduced to preserve key ordering

      https://github.com/mongodb/mongo-tools/commit/edf81c46753bf0c3a9522c8e38c9fb124d2cfe01

      reflect.Value.Type(0x0, 0x0, 0x0, 0x0, 0x0)
      	/usr/local/go/src/reflect/value.go:1633 +0x8c
      github.com/mongodb/mongo-tools/mongoexport.extractFieldByName(0x7ffe8d3247f1, 0xe, 0x7bc180, 0xc2080d4150, 0x0, 0x0, 0x0, 0x0)
      	/data/mci/src/src/mongo-tools-repo/.gopath/src/github.com/mongodb/mongo-tools/mongoexport/csv.go:96 +0x177
      github.com/mongodb/mongo-tools/mongoexport.(*CSVExportOutput).ExportDocument(0xc2080c40f0, 0xc2080d4150, 0x0, 0x0)
      	/data/mci/src/src/mongo-tools-repo/.gopath/src/github.com/mongodb/mongo-tools/mongoexport/csv.go:65 +0x1b1
      github.com/mongodb/mongo-tools/mongoexport.(*MongoExport).exportInternal(0xc20800a0b0, 0x7ff4dab30c90, 0xc20803a198, 0x0, 0x0, 0x0)
      	/data/mci/src/src/mongo-tools-repo/.gopath/src/github.com/mongodb/mongo-tools/mongoexport/mongoexport.go:258 +0x401
      github.com/mongodb/mongo-tools/mongoexport.(*MongoExport).Export(0xc20800a0b0, 0x7ff4dab30c90, 0xc20803a198, 0x7ff4dab30c90, 0x0, 0x0)
      	/data/mci/src/src/mongo-tools-repo/.gopath/src/github.com/mongodb/mongo-tools/mongoexport/mongoexport.go:281 +0x4e
      main.main()
      	/data/mci/src/src/mongo-tools-repo/mongoexport/main/mongoexport.go:84 +0xabc
      
      goroutine 5 [syscall]:
      os/signal.loop()
      

            Assignee:
            Kyle Erf (Inactive)
            Reporter:
            Christopher Kung
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: