Repository navigation
fix: keep a resolve no louder than its incident for ntfy, Gotify and Pushover - #592
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #591
A resolve could be louder than the incident it closed: ntfy always sent resolves at 3, Gotify omitted the priority so the server default applied, and Pushover sent resolves at 0 even when the configured priority was negative.
transport.ResolvePriority(configured, override, normal): an explicit override wins, otherwise the configured priority is capped at the provider's normal level; an unset priority behaves as before.alert.<provider>.resolvedPriorityfor ntfy (1-5), Gotify (0-10) and Pushover (-2 to 1).resolvedPriorityof 2 (or out of range) is rejected at startup, like an invalidpriority. For ntfy and Gotify an out-of-range value is logged and ignored.transport.IntSettingreplaces the duplicated float64/int/int64 switch in ntfy, Gotify, Pushover and ClickUp.Behaviour change: setups with a low priority now get equally quiet resolves, and Gotify setups with a priority above 5 get resolves capped at 5 instead of the server default.