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

Support geoJson with 2d index

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Major - P3
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: Backlog
    • Component/s: Geo, Index Maintenance
    • Labels:
      None

      Description

      As documented hereĀ https://docs.mongodb.com/manual/core/2d/ 2d Indexes can not be used to store GeoJSON and for this kind of geometries the correct index should be the 2dsphere.

      Trying to load polygons conceived in a plane with a 2dsphere index is possible to receive an error like:

      Edges 171 and 221 cross. Edge locations in degrees: [-180.0000000, 85.0511500]-[-180.0000000, 0.0000000] and [-180.0000000, -74.5979195]-[-180.0000000, -85.0511500]
      

      I don't want to discuss the error above, for me is clear. The problem is that there are professional sectors where most of the available geometry resources are "flat" and also the adopted software tools make this assumption.

      The error above for example refers to the polygon of a Sentinel dataset provided by the ESA but affects also datasets/geometry provided by NASA, USGS and so on. The provided field of view of this rasters are not wrong but are coordinates mapped on a plane not on a sphere.

      Sorry if I went too long. Summarising, what in my opinion should be useful is the support of geoJson also with a 2d index.

      Thanks

      Damiano

        Attachments

          Activity

            People

            Assignee:
            backlog-query-optimization Backlog - Query Optimization
            Reporter:
            barboni@meeo.it Damiano Barboni
            Participants:
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Dates

              Created:
              Updated: