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

Accuracy differences in geoNear aggregation between mongod 5.0 and 6.0

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 6.0.8
    • Component/s: None
    • None
    • Server Triage
    • ALL

      The results of geoNear example are different on mongo 5.0 and 6.0.

      9.539931676365992 against 9.539931674131209

      https://www.mongodb.com/docs/manual/reference/operator/aggregation/geoNear/

      Therefore, some unit test failed.

      https://github.com/mongodb/mongo-java-driver/blob/master/driver-core/src/test/functional/com/mongodb/client/model/AggregatesTest.java#L237

       

      Result of mongo 5.0.17:

      [{"_id": 2, "name": "Sara D. Roosevelt Park", "category": "Parks", "location":

      {"type": "Point", "coordinates": [-73.9928, 40.7193]}

      , "dist": {"calculated": 9.539931676365992, "location":

      {"type": "Point", "coordinates": [-73.9928, 40.7193]}

      }}]

       

      Result of mongo 6.0.8:

      [{"_id": 2, "name": "Sara D. Roosevelt Park", "location":

      {"type": "Point", "coordinates": [-73.9928, 40.7193]}

      , "category": "Parks", "dist": {"calculated": 9.539931674131209, "location":

      {"type": "Point", "coordinates": [-73.9928, 40.7193]}

      }}]

            Assignee:
            backlog-server-triage [HELP ONLY] Backlog - Triage Team
            Reporter:
            lzy@luozy.cn 罗震宇 N/A
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: