Operational Defect Database

BugZero found this defect 363 days ago.

MongoDB | 2347282

listIndexes on timeseries collection doesn’t include 2dsphereIndexVersion

Last update date:

3/12/2024

Affected products:

MongoDB Server

Affected releases:

No affected releases provided.

Fixed releases:

7.1.0-rc0

Description:

Info

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.

Top User Comments

xgen-internal-githook commented on Mon, 24 Jul 2023 21:32:25 +0000: Author: {'name': 'Malik Endsley', 'email': 'malik.endsley@mongodb.com', 'username': 'malikendsley'} Message: SERVER-77374 Include 2dsphereIndexVersion field on timeseries indexes Branch: master https://github.com/mongodb/mongo/commit/7391fe3982d32c057571e4d78a53018570a2717c gregory.noma commented on Tue, 20 Jun 2023 15:51:50 +0000: We may want to also make sure this doesn't happen for any other index types

Steps to Reproduce

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 >

Additional Resources / Links

Share:

BugZero® Risk Score

What's this?

Coming soon

Status

Closed

Learn More

Search:

...