[SERVER-22448] Query planner does not filter 2dsphere Index Version 3 correctly Created: 03/Feb/16  Updated: 19/Nov/16  Resolved: 03/Feb/16

Status: Closed
Project: Core Server
Component/s: Geo, Querying
Affects Version/s: 3.2.1
Fix Version/s: 3.2.3, 3.3.2

Type: Bug Priority: Critical - P2
Reporter: James O'Leary Assignee: David Storch
Resolution: Done Votes: 0
Labels: code-and-test
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Completed:
Steps To Reproduce:
  1. Create a 2dsphere index in 3.2.1
  2. add a document without coordinates
  3. query for this document (none will be found)

Running the same query with a 2dsphereIndexVersion will return a document but is a collection scan for 2dsphereIndexVersion 2

Sprint: Query 10 (02/22/16)
Participants:

 Description   

The implementation of QueryPlannerIXSelect::stripInvalidAssignmentsTo2dsphereIndices filters version 2 2dsphere indexes (as they are sparse).

However, version 3 of these indexes are not filtered. As a result, they can be selected as a winning plan and documents not in the index cannot be found.

It should be noted that filtering these indexes out may result in a collection scan which will find documents but at the cost of poor performance.



 Comments   
Comment by Githook User [ 03/Feb/16 ]

Author:

{u'username': u'dstorch', u'name': u'David Storch', u'email': u'david.storch@10gen.com'}

Message: SERVER-22448 fix geo-sparseness planning for 2dsphereIndexVersion 3

(cherry picked from commit 2c310b34126db69d14150318883c8d0ab24c8d34)
Branch: v3.2
https://github.com/mongodb/mongo/commit/9cf9323912eb732ed4c6ced5f926e1e0bca46e9f

Comment by Githook User [ 03/Feb/16 ]

Author:

{u'username': u'dstorch', u'name': u'David Storch', u'email': u'david.storch@10gen.com'}

Message: SERVER-22448 fix geo-sparseness planning for 2dsphereIndexVersion 3
Branch: master
https://github.com/mongodb/mongo/commit/2c310b34126db69d14150318883c8d0ab24c8d34

Generated at Thu Feb 08 04:00:26 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.