-
Notifications
You must be signed in to change notification settings - Fork 92
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
OSD-22337 route some customer alerts to null receiver #342
base: master
Are you sure you want to change the base?
OSD-22337 route some customer alerts to null receiver #342
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: tkong-redhat The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #342 +/- ##
==========================================
+ Coverage 66.01% 66.19% +0.18%
==========================================
Files 7 7
Lines 915 920 +5
==========================================
+ Hits 604 609 +5
Misses 288 288
Partials 23 23
|
/hold for discussion |
@@ -457,6 +457,13 @@ func createSubroutes(namespaceList []string, receiver receiverType) *alertmanage | |||
// Route ClusterOperatorDown for insights to null receiver https://issues.redhat.com/browse/OSD-19800 | |||
// Also needs to be silenced for FedRAMP until its made available in the environment https://issues.redhat.com/browse/OSD-13685 | |||
{Receiver: receiverNull, Match: map[string]string{"alertname": "ClusterOperatorDown", "name": "insights"}}, | |||
// Route some customer defined alerts to null receiver | |||
// https://issues.redhat.com/browse/OSD-22337 | |||
{Receiver: receiverNull, Match: map[string]string{"alertname": "memory-request"}}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not a great long term solution to filter on alertname, is there a better way to identify these "user defined" alerts?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a short term solution. There is no easy way to identify those "user defined" alerts. We had several discussion about this. There is a doc about our finding https://docs.google.com/document/d/1OscbdlZ-aBuwY7YKJsU5URyDvfS9A4-VV4yBhpowfy4/edit#heading=h.i7a6b1h441g
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should use some better labels to distinguish between Red Hat defined alert and user defined alert. But that requires more discussion and nearly impact all the existing alerts. That's why we put a short term solution here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not a great long term solution to filter on alertname, is there a better way to identify these "user defined" alerts?
Agree, looks this PR’s current logic relies on matching specific alertname values
to identify user-defined alerts and route them to a null. However, if any change in the alert name or new customer-defined alerts not explicitly added in this list can bypass the receiever.
probably use a label user_alert=true
or something similar to match alerts instead of relying on alertnames?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TBH, I would prefer long term solution which is adding some common labels so we could easily distinguish user defined alerts and Red Hat defined alerts. That would be lovely and this makes our life easier. Unfortunately, we don't have this type of definition in any our docs, so there is no standard labels to be used ATM. It requires a lot of effort to discuss with BU and wider teams about what should be the labels used and make a agreement.
@tkong-redhat: The following tests failed, say
Full PR test history. Your PR dashboard. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
PR needs rebase. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
There are some customer defined alerts which are picked up by CAMO and routed to Red Hat pagerduty due to customer set some labels with Red Hat managed namespaces.
Adding some route rules to redirect those alerts to NULL receiver so that Red Hat SRE will not be paged.
Rule has been tested on a stg cluster.