-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Requested feature] Server endpoint to interact with references saved in cache #40
Comments
This feature was back of my head for some time. |
Thanks for the effort! |
feat: view cache; delete cache; test cases for server; closes #40
@theisuru, even though this issue was closed, and I guess addressed in the PR, is there documentation anywhere on how to use this new feature to refresh the cache of the server? |
@theisuru if there is any documentation eventually for the cache interactions, please let me know! |
@M-casado sorry about the late response. We only have minimal entry in |
Hi @theisuru, thanks for reopening the issue: although the feature was technically implemente, without documentation it'll be difficult to make use of. Besides, I would also like to address the other two features:
Without the latter, I foresee an easy route of attack that would incredibly hinder the validation efficiency: the deletion of our cache would require the download of the schemas at every request, which would make requests go from mili-seconds to ~10s. |
Summary
A feature (probably endpoint) to interact with references saved in cache of a Biovalidator server:
Motivation
When using URL-resolvable references for schemas, once any reference is used, it is stored in cache, avoiding its repeated download. This feature is very useful dealing with the delay of downloading referenced schemas. Nevertheless, at some point one may change the URL-resolved reference, and would want those modifications to propagate to the validation server without changing the referenced schema name (
"$ref"
). If the references are still stored in cache, the server will not grab the modified schemas, and would instead use the obsolete ones.Therefore, we request an endpoint that allows for the server deployers to:
Examples
Example 1
My schema is used as the "latest version" reference. I notice a mistake and amend it. But I already used the validation tool, which stored the previous version of the schema. I would then want to manually refresh the cache of the server for it to grab the newer version.
Example 2
I would want to incorporate in my GitHub actions one that automatically pings the refresh endpoint whenever a new change is merged with the
main
branch. That way, changes in the GitHub repository I use to store my schemas would always propagate to the validation API.Example 3
I would like to create a script that automatically checks if the schemas have not been refreshed for longer than a week (using the second requested feature) and, if so, automatically refresh them (using the first requested feature).
The text was updated successfully, but these errors were encountered: