[SERVER-2134] indexed geo search slower than index-less naive search Created: 22/Nov/10 Updated: 12/Jul/16 Resolved: 04/Apr/11 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Geo, Index Maintenance, Performance |
| Affects Version/s: | 1.7.3 |
| Fix Version/s: | 1.9.0 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Brandon Heller | Assignee: | Greg Studer |
| Resolution: | Done | Votes: | 3 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Same issue seen w/1.6.4 on Linux 64 and on 1.7.3 w/ OS X 64bit. |
||
| Attachments: |
|
| Participants: |
| Description |
|
I would like to do geo queries against a collection with 1M docs or At large sizes (1M), an indexed geo query is slower than a naive javascript search. At 100K commits, the geo search is faster. More details on the mongodb-user list thread at: http://groups.google.com/group/mongodb-user/browse_thread/thread/7bcce8a4d58c44c3 Full data from mongodump on the db is attached (compressed). |
| Comments |
| Comment by auto [ 04/Apr/11 ] |
|
Author: {u'login': u'gregstuder', u'name': u'gregs', u'email': u'greg@10gen.com'}Message: better $within performance on large 2d queries incremental expansion on both center and neighbor boxes for geo-searching |
| Comment by Greg Studer [ 29/Mar/11 ] |
|
Still need to perform the same checks on box-neighbors. |
| Comment by auto [ 29/Mar/11 ] |
|
Author: {u'login': u'gregstuder', u'name': u'gregs', u'email': u'greg@10gen.com'}Message: avoid box expand performance cliff with clustered points |
| Comment by Greg Studer [ 29/Mar/11 ] |
|
Issue is the box-expand algorithm of geo-queries tries to buffer all points contained in the new box expansion. When points are highly clustered, there can be a box expand "cliff" where a new box expansion contains most/all of the points, and they are all checked/stored at once. Solution is to buffer only a limited number of points each time we run out, and expand again only when we need more points. Same issues would/do hold for $within $center queries. |