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

2.6 upgrade checker checks only for presence of _id index, not uniqueness

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Major - P3 Major - P3
    • None
    • 2.6.0-rc1
    • Admin
    • None
    • ALL

    Description

      When running the upgrade checker, if a collection has an index on "_id" it doesn't complain if the index isn't unique, which generates a startup warning.

      Upgrade checker output

      www-c:SECONDARY> db.upgradeCheck({db: "aux_www_devel", collection: "web_exceptions"})
      Checking collection 'aux_www_devel.web_exceptions' for 2.6 upgrade compatibility
       
      Checking collection aux_www_devel.web_exceptions
      Everything in 'aux_www_devel.web_exceptions' is ready for the upgrade!
      true

      Get indexes output

      www-c:SECONDARY> use aux_www_devel
      switched to db aux_www_devel
      www-c:SECONDARY> db.web_exceptions.getIndexes()
      [
      	{
      		"v" : 1,
      		"key" : {
      			"_id" : 1
      		},
      		"ns" : "aux_www_devel.web_exceptions",
      		"name" : "_id_"
      	}
      ]

      Attachments

        Activity

          People

            matt.dannenberg Matt Dannenberg
            jonathan.reams@mongodb.com Jonathan Reams
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: