CatalogueOfLife / backend

Complete backend of COL ChecklistBank
Apache License 2.0
15 stars 11 forks source link

Include support for external IDs within an index #1308

Open djtfmartin opened 6 months ago

djtfmartin commented 6 months ago

It would be helpful to support resolution of external IDs for a checklist. An example being AphiaID from WoRMS.

This may come from using multivalued field in lucene that we use for matching on ID. As we are thinking of an index per checklist, then these IDs should be unique within a particular checklist index.

These IDs should be included in web service responses so that they can be used occurrence indexing, and hence support lookups of occurrence records by external IDs.

mdoering commented 6 months ago

You mean having Aphia WoRMS IDs inside a lookup index for the COL Checklist for example? I think I would avoid that, as it relies on a mapping at the time of building the index and that information can get out of date much quicker. It would require a lot more index builds and becomes harder to understand when it actually is out of date.

Unless the identifiers are actually included in the dataset itself. There is an alternative identifiers array for name usage for example that we could expose for lookups. These might be external identifiers or just alternative representations of local ones, e.g. URIs for integers. It is not used much at this stage, but could be more useful in the future.