You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Expected behavior
Synonyms should not be mandatory for a select or search API call.
Screenshots
Error 500 select API:
Error 500 search API:
Error from the log:
Error Message
The log provides a hint what the issue is. ols4-ols4-solr-1 | 2024-10-10 14:22:24.513 ERROR (qtp1394940518-25) [ x:ols4_entities] o.a.s.h.RequestHandlerBase org.apache.solr.common.SolrException: org.apache.solr.search.SyntaxError: Query Field 'synonym' is not a valid field name
Additional context
I also indexed a second file without a synonym and the error still appears. When I add one synonym to a file the select and the search API is working as expected.
The text was updated successfully, but these errors were encountered:
further investigating the issue @rombaum i believe the issue is because of a assumption in Select and Search controllers. In OLS world we assume that our solr documents have the following fields available {"label", "synonym", "short_form", "obo_id", "iri", "annotations_trimmed"}
For OLS, this error doesn't arrive because we are indexing a few hundred ontologies which are bound to have synonyms, short_form etc. So whenever a search with q=* happens solr doesn't complain that it can't find the field.
If your requirement is that you want to run the OLS instance with only one ontology that does not have some of the fields mentioned above, then I would suggest you update the Search and Select controllers as per your requirement.
Please let me know if you need any further help or information regarding this.
Describe the bug
If indexed ontologies doesn't have at least one synonym the search and the select API delivers a Whitelabel Error Page.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Synonyms should not be mandatory for a select or search API call.
Screenshots
Error 500 select API:
Error 500 search API:
Error from the log:
Error Message
The log provides a hint what the issue is.
ols4-ols4-solr-1 | 2024-10-10 14:22:24.513 ERROR (qtp1394940518-25) [ x:ols4_entities] o.a.s.h.RequestHandlerBase org.apache.solr.common.SolrException: org.apache.solr.search.SyntaxError: Query Field 'synonym' is not a valid field name
Upload minimal complete example
Config file: file-without-synonym.json
Owl file without synonym: file-without-synonym.zip
Owl file with synonym: file-with-synonym.zip
Additional context
I also indexed a second file without a synonym and the error still appears. When I add one synonym to a file the select and the search API is working as expected.
The text was updated successfully, but these errors were encountered: