clarin-eric / fcs-sru-aggregator

CLARIN Federated Content Search v3 Aggregator – Augmenting your Search Engine
GNU General Public License v3.0
7 stars 2 forks source link

Expose declared layers from resources in endpoint-description to frondent for filtering #70

Open Querela opened 1 year ago

Querela commented 1 year ago

Endpoints use the endpoint description to specify resources, search capabilities and in case of ADV search which layers are searchable. It would be nice to forward those [resource layer definitions] to the frontend to only show/highlight those resources or fields (layers) that can be searched. Otherwise, endpoints will always respond with some diagnostic (either simplifying the query or not performing a search at all). Communicating this to the user makes it more clear what can be searched.

It probably would be good to still send the queries to endpoints/resources that tell us they do not support some layer to keep the behaviour as is. But selecting fields/resources for searching can be improved.

Querela commented 1 year ago

NOTE: also expose resolved capabilities of resources? I.e. use the capabilities of the endpoint as a basis and for each resource then reduce the set to those that are really usable? That means an endpoint with advanced-search capability can have resources that do not respond with an advanced data view so they should in effect only have the basic-search capability. This will allow to improve the frontend to only show resources for specific query types that the resource really can handle. And while now the aggregator can send requests with unsupported query types to some resources (really an edge case), the endpoints should respond with (non-)fatal diagnostics. This would for certain cases reduce the amount of requests being sent and also improve response times if one endpoint has many resources with different capability (data view) sets.

Querela commented 1 year ago

See commit: dcadb41f2189b0754ab4cedcab091bc01e0cb690