OHDSI / WebAPI

OHDSI WebAPI contains all OHDSI services that can be called from OHDSI applications
Apache License 2.0
130 stars 169 forks source link

Clear Server Cache button in ATLAS does not work #2274

Open konstjar opened 1 year ago

konstjar commented 1 year ago

Expected behaviour

ATLAS has "Clear Server Cache" button on Configuration page. Expected that endpoint is present and it clears all in-memory cache and truncates "cdm_cache" table in application database. Maybe anything else?

Actual behavior

Clicking it request goes to WebAPI/cache/clear endpoint that does not exist. 404 comes as response. API Documentation does not show the endpoint too: http://webapidoc.ohdsi.org

Steps to reproduce behavior

  1. Enable authentication in ATLAS/WebAPI
  2. Open Configuration page with "admin" role
  3. Click "Clear Server Cache" button
chrisknoll commented 1 year ago

Possible dupe of https://github.com/OHDSI/Atlas/issues/2847.

anthonysena commented 11 months ago

For reference, we're referring to this button:

Image

The proposed behavior should be: clear all results from the WebAPI cdm_cache and achilles_results_cache tables. This would work across all cached data sources configured in WebAPI. Perhaps we rename this button "Clear WebAPI cache"?

Question: should this only clear the cached data in the WebAPI database and/or the CDM(s) results table(s)?

For this button:

Image

We'd clear the table that holds the achilles_record_count and re-build and re-cache this information in the WebAPI database? Perhaps we need to rename this "refresh record count cache"?

anthonysena commented 4 months ago

Noting the WebAPI endpoints for the buttons above: