Skip to content

Commit

Permalink
Change /reset-tbox-cache endpoint back to /purge-tbox-cache after dis…
Browse files Browse the repository at this point in the history
…cussion on PR.
  • Loading branch information
recalcitrantsupplant committed Sep 27, 2023
1 parent 8efcdd8 commit fd507b1
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions prez/routers/management.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,13 @@
router = APIRouter(tags=["Management"])


@router.get("/reset-tbox-cache", summary="Reset Tbox Cache")
async def reset_tbox_cache():
"""Resets the Tbox cache to startup state - included ontologies only."""
@router.get("/purge-tbox-cache", summary="Reset Tbox Cache")
async def purge_tbox_cache():
"""Purges the tbox cache, then re-adds annotations from common ontologies Prez has a copy of
(reference_data/context_ontologies)."""
tbox_cache.remove((None, None, None))
await add_common_context_ontologies_to_tbox_cache()
return PlainTextResponse("Tbox cache reset")
return PlainTextResponse("Tbox cache purged and reset to startup state")


@router.get("/tbox-cache", summary="Show the Tbox Cache")
Expand Down

0 comments on commit fd507b1

Please sign in to comment.