Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor spatial search to use modern Solr options #291

Open
amercader opened this issue Aug 22, 2022 · 0 comments
Open

Refactor spatial search to use modern Solr options #291

amercader opened this issue Aug 22, 2022 · 0 comments

Comments

@amercader
Copy link
Member

Solr documentation: https://solr.apache.org/guide/8_11/spatial-search.html

The Postgis search option will be dropped.

Of the other two remaining ones:

  • solr is based on bounding boxes, both in the geometries indexed and and the input query geometries, and it doesn't actually use any spatial library underneath, just math operations performed on values indexed. This could be replaced by the BBoxField which provides the same functionality in Solr
  • solr-spatial-field is based on actual spatial operations powered by JTS (or Geo3D) in Solr, using the SpatialRecursivePrefixTreeFieldType or RPT field type. It supports points, polygons and bboxes so we can probably combine both modes of operation.

Things to explore:

  • RPT might require and additional LatLonPointSpatialField for sorting (see note in RPT
  • Solr supports WKT for indexing geometries, can we support it in our spatial field?
  • It would be interesting to provide a mechanism for extensions to index geometries that are not stored in the spatial field, eg from a lookup table, to avoid storing big values in the dataset metadata. Maybe this is just a matter of providing a pattern for overriding the before_dataset_index() method

A pre-built Docker image will be provided to facilitate the installation and usage, as well to be able to write tests against a spatially enabled version. See ckan/ckan-solr#5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant