hubmapconsortium / antibody-api

API for the Antibody DB.
https://avr.hubmapconsortium.org/
0 stars 0 forks source link

Faceted search/all UI Elasticsearch calls through `search-api` #13

Closed shirey closed 2 years ago

shirey commented 2 years ago

All calls from the browser to Elasticsearch need to be routed through the search-api web service. Direct access to Elasticsearch is only allowed through a white list of IP addresses which would break public access for the faceted search UI.

Because the Antibody API writes to a PostgreSQL database as well as Elastic Search when data is entered, and because there is no method of writing to Elastic Search through the Search API, the writing portion will remain in the Antibody API.

Currently the testing will be done by running the Antibody API service in Docker containers on localhost, and the Search API directly on localhost. Documentation of what changes need to be made to implement the tests will be written to the README.dm file under the heading "Using the SearchAPI instead of directly reading from Elastic Search"

gorandev commented 2 years ago

@shirey Browser is not hitting Elasticsearch directly: it hits the antibody-api which, in turn, connects directly to Elasticsearch.