o19s / splainer-search

Angular JS Solr and Elasticsearch and OpenSearch Diagnostic Search Services
Apache License 2.0
25 stars 23 forks source link

Search engine searchapi does not support retrieving per doc metadata directly #140

Closed dacox closed 10 months ago

dacox commented 10 months ago

Describe the bug When using the searchapi searchengine, I get the following error:

Search engine searchapi does not support retrieving per doc metadata directly

To Reproduce

Using the newly pushed docker image released after https://github.com/o19s/quepid/issues/890

https://hub.docker.com/layers/o19s/quepid/latest/images/sha256-bb94695eb976fa83e51c71c49436e9da3063d720607ed9961aca7c8399e372a7

Load a Case that uses searchapi - the case never loads results.

Name: None specified, using generated name

Search engine:  searchapi

Endpoint url: http://name-of-internal-service/search/

Custom headers: { "Authorization": "Token BLAHBLAHBLAH", "Accept": "application/json", "Content-Type": "application/json", "FOO": "BAR"}

API method: POST

Proxy Requests: true

Basic Auth Credential: 0

Options:

Custom Code Mapper:

numberOfResultsMapper = function(data){
  return data.length
};

docsMapper = function(data){...

Expected behavior

The case should not error

Screenshots

Screenshot 2023-11-30 at 11 32 04 AM

Additional context

I have tracked it down to https://github.com/o19s/splainer-search/commit/9034c0bb86a42828a66efc4badcae0e687302b23

epugh commented 10 months ago

This was fixed in #141... If it itsn't working for you, please reopen this ticket!