Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-16634

[SERVER] Investigate changes in SERVER-84598: $geoNear allows missing or invalid GeoJSON "type" field

      Original Downstream Change Summary

      Just a heads up for docs that even though this behavior was technically not allowed before, it will now error.

      Description of Linked Ticket

      Most geo queries that are built on top of geometry_container do not allow an unknown or missing "type" field. However, $geoNear (match expression and agg stage) rely instead on `GeoNearExpression`, which skips the geometry_container layer, so it accepts a missing or invalid GeoJSON "type" field, and will treat it as type "Point". In fact, it would even accept the type field as any GeoJSON type, since it doesn't check the "type" field. This is misleading, and inconsistent with the other geo operators.

      As part of this ticket, we should consider incorporating geometry_container as part of GeoNearExpression to match behavior parity across geo expressions.

            Assignee:
            Unassigned Unassigned
            Reporter:
            backlog-server-pm Backlog - Core Eng Program Management Team
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              10 weeks, 5 days ago