-
-
Notifications
You must be signed in to change notification settings - Fork 48
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
Uses newest scoring timestamp as etag header #472
Uses newest scoring timestamp as etag header #472
Conversation
@lemeurherve is that enough or should we have something in front of the |
I don't know. |
I definitively would be in favor of a static export of everything like it's done for other sources of data for plugin-site instead of an API, but that's a discussion not directly related to this PR. |
Looking again at the linked issue, that's in fact related. #373 is about having a static export in https://reports.jenkins.io instead of an API to pass data to plugin-site. |
don't resolve the issue as I intended initially
Locally, this makes the original 6.9MB shrinks to 3.5MB file.
Co-Authored-By: Hervé Le Meur <lemeurherve.jenkins@gmail.com>
Co-Authored-By: Hervé Le Meur <lemeurherve.jenkins@gmail.com>
Co-Authored-By: Hervé Le Meur <lemeurherve.jenkins@gmail.com>
Co-Authored-By: Hervé Le Meur <lemeurherve.jenkins@gmail.com>
Description
Closes #373.
Not all scores are computed all the time. For a score to be computed again on a plugin, probe results on the plugin have to be updated (more recent than last execution of the score) and the scoring implementation must have the same version as on its last execution.
Because of that, we know that the most recent score computed, across all the plugins, will determine if the content of the
/scores/api
has changed since the last time it was fetched.This puts the value of the seconds since epoch of the most recent scoring execution in the
ETag
header of the response.Testing done
Adjusted the unit test on the API to validate the presence and value of the
ETag
header.Submitter checklist