Skip to content
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

Dismiss pruning alerts for contract IDs that are no longer prunable #1240

Merged
merged 4 commits into from
May 22, 2024

Conversation

peterjan
Copy link
Member

@peterjan peterjan commented May 16, 2024

As the title suggests this PR dismisses stale prune alerts. This is important because we currently don't dismiss alerts if the contracts is not listed as prunable, this can be because it dropped out of the contract set but also on renewals for instance. It's kind of annoying to do this though because alert IDs are hashes but the state I had to keep is very very minimal imo. Took the opportunity to get rid of pruneResult which has always bothered me a bit. I also changed it so we only send a metric when either the error was nil or we managed to pruned at least 1 byte. That makes sense I think, we currently log metrics for failures too but not sure why we did that in the first place.

@peterjan peterjan self-assigned this May 16, 2024
@peterjan peterjan marked this pull request as ready for review May 17, 2024 09:01
autopilot/alerts.go Show resolved Hide resolved
autopilot/contract_pruning.go Show resolved Hide resolved
@ChrisSchinnerl ChrisSchinnerl merged commit 7fef04a into dev May 22, 2024
7 checks passed
@ChrisSchinnerl ChrisSchinnerl deleted the pj/dismiss-pruning-alerts branch May 22, 2024 08:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants