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

listIndexes on timeseries collection doesn’t include 2dsphereIndexVersion

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Storage Execution
    • Fully Compatible
    • ALL
    • Hide
      MongoDB Enterprise > db.createCollection("timeseries", {timeseries: {timeField: "t"}})
      MongoDB Enterprise > db.timeseries.createIndex({x: "2dsphere"})
      MongoDB Enterprise > db.timeseries.getIndexes()
      [
              {
                      "v" : 2,
                      "key" : {
                              "x" : "2dsphere"
                      },
                      "name" : "x_2dsphere"
              }
      ]
      MongoDB Enterprise > db.system.buckets.timeseries.getIndexes()
      [
              {
                      "v" : 2,
                      "key" : {
                              "data.x" : "2dsphere_bucket"
                      },
                      "name" : "x_2dsphere",
                      "2dsphereIndexVersion" : 3,
                      "originalSpec" : {
                              "key" : {
                                      "x" : "2dsphere"
                              },
                              "name" : "x_2dsphere",
                              "v" : 2
                      }
              }
      ]
      MongoDB Enterprise > db.nontimeseries.createIndex({x: "2dsphere"})
      MongoDB Enterprise > db.nontimeseries.getIndexes()
      [
              {
                      "v" : 2,
                      "key" : {
                              "_id" : 1
                      },
                      "name" : "_id_"
              },
              {
                      "v" : 2,
                      "key" : {
                              "x" : "2dsphere"
                      },
                      "name" : "x_2dsphere",
                      "2dsphereIndexVersion" : 3
              }
      ]
      MongoDB Enterprise >  
      
      Show
      MongoDB Enterprise > db.createCollection( "timeseries" , {timeseries: {timeField: "t" }}) MongoDB Enterprise > db.timeseries.createIndex({x: "2dsphere" }) MongoDB Enterprise > db.timeseries.getIndexes() [ { "v" : 2, "key" : { "x" : "2dsphere" }, "name" : "x_2dsphere" } ] MongoDB Enterprise > db.system.buckets.timeseries.getIndexes() [ { "v" : 2, "key" : { "data.x" : "2dsphere_bucket" }, "name" : "x_2dsphere" , "2dsphereIndexVersion" : 3, "originalSpec" : { "key" : { "x" : "2dsphere" }, "name" : "x_2dsphere" , "v" : 2 } } ] MongoDB Enterprise > db.nontimeseries.createIndex({x: "2dsphere" }) MongoDB Enterprise > db.nontimeseries.getIndexes() [ { "v" : 2, "key" : { "_id" : 1 }, "name" : "_id_" }, { "v" : 2, "key" : { "x" : "2dsphere" }, "name" : "x_2dsphere" , "2dsphereIndexVersion" : 3 } ] MongoDB Enterprise >
    • Execution NAMR Team 2023-07-10, Execution NAMR Team 2023-07-24, Execution NAMR Team 2023-08-07, QI 2023-06-12
    • 0

      listIndexes on normal collections and the system.buckets collection include a 2dsphereIndexVersion field in the response for a 2dsphere index, but listIndexes on the timeseries view does not.

       

      This block seems to be the culprit, because the index version field is on the top-level index spec object and not the originalSpec sub-object.

            Assignee:
            malik.endsley@mongodb.com Malik Endsley
            Reporter:
            alyssa.clark@mongodb.com Alyssa Clark
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: