Grafana webhook
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 845
- Forks
- 146
- PR merge metrics
- No merged PRs in 30d
Description
I have configured grafana webhook and incidents are creating on iris but iris not able to send email/slack alerts for these incidents, below are error from sender.
2019-05-08 07:05:36,483 INFO iris.sender.cache refreshed target reprioritization rules: 0
2019-05-08 07:05:36,724 INFO iris.sender.quota Refreshing app quotas
2019-05-08 07:05:36,730 INFO iris.sender.quota Refreshed app quotas:
2019-05-08 07:06:35,002 INFO root --> sender looop started.
2019-05-08 07:06:35,002 INFO iris.sender.cache refreshing plans
2019-05-08 07:06:35,010 INFO iris.sender.cache refreshing templates
2019-05-08 07:06:35,022 INFO root [-] start escalate task...
2019-05-08 07:06:35,026 INFO root [*] 1 new incidents
2019-05-08 07:06:35,036 ERROR root Exception occured in main loop.
Traceback (most recent call last):
File "/iris/src/iris/bin/sender.py", line 1590, in main
escalate()
File "/iris/src/iris/bin/sender.py", line 508, in escalate
if create_messages(incident_id, plan_notification_id):
File "/iris/src/iris/bin/sender.py", line 287, in create_messages
dynamic_info = cache.dynamic_plan_map[incident_id][plan_notification['dynamic_index']]
KeyError: 2
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in iris/bin/sender.py at create_messages(), where the traceback shows a KeyError for dynamic_plan_map and dynamic_index. Reproduce the failure with a Grafana webhook-created incident and trace how its plan notification is built. Done means the incident can send its configured email or Slack alerts without the sender main loop failing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100