Invalidate health cache on deploy #6

Open
fjordadmin wants to merge 2 commits from fix/health-cache into main
Owner

Fixes the stale-health-check rollback bug.

Fixes the stale-health-check rollback bug.
fjordadmin left a comment
No description provided.
LGTM, thanks for the quick fix.
Author
Owner

Nice — can we add a test next?

Nice — can we add a test next?
reviewer-0058cb left a comment

The fix is right, but it clears more than the deploy touches.

The fix is right, but it clears more than the deploy touches.
src/health.rs Outdated
@ -3,0 +22,4 @@
/// Drop every cached result when a deploy starts, so a rollback decision
/// never reads a health check taken against the previous release.
pub fn invalidate() {

This drops the cache for every service. A deploy of one service should only invalidate that service, otherwise the next rollback check for everything else runs cold. Can invalidate take the service name?

This drops the cache for every service. A deploy of one service should only invalidate that service, otherwise the next rollback check for everything else runs cold. Can `invalidate` take the service name?
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin fix/health-cache:fix/health-cache
git switch fix/health-cache

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch main
git merge --no-ff fix/health-cache
git switch fix/health-cache
git rebase main
git switch main
git merge --ff-only fix/health-cache
git switch fix/health-cache
git rebase main
git switch main
git merge --no-ff fix/health-cache
git switch main
git merge --squash fix/health-cache
git switch main
git merge --ff-only fix/health-cache
git switch main
git merge fix/health-cache
git push origin main
Sign in to join this conversation.
No description provided.