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

add cron-schedule support to alerts by changing IsEnabled result #442

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

umputun
Copy link

@umputun umputun commented Feb 22, 2023

The change is back-compatible. It suppresses alerts outside the user-defined crontab format schedule by setting enabled to false.

The goal is to suppress alerts with user-provided crontab formatted settings. It is somewhat similar to the current maintenance but allows more flexibility in setting the schedule. For example, if cron-schedule is set to * 9-18 * * the alert will be disabled before 9:00 and after 18:59. I think, adding it on the Alert level is the simplest solution here with the minimal code change.

See discussion #250.

Checklist

  • Tested and/or added tests to validate that the changes work as intended, if applicable.
  • Added the documentation in README.md, if applicable.

Note: I'm not sure what is the proper section in the readme to add this info

The change is back-compatible. It suppresses alerts outside defined cron-format schedule by setting enabled to false
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant