Changes to the way HTTPPost works in ElastAlert #80
Locked
Shashankft9
started this conversation in
Ideas
Replies: 1 comment
-
This might make sense as a new "CloudEvent" alerter rather than increasing the complexity of the POST alerter. I'm interested in others' thoughts on it. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hey, currently when alert type is chosen to be post in the rule as
alert: post
, elastalert sends an alert to the url using HTTP protocol which makes sense, but I have been recently using something called CloudEvents, which is basically a specification for sending events (alerts) for an event driven architecture:https://cloudevents.io/
https://github.com/cloudevents/spec/blob/v1.0/spec.md
Would it make sense to incorporate this specification here in http post alert type? This wouldnt change the request headers, but data will be changed as per the spec, basically it will contain the complete cloudevent with its attributes, something like this:
It would be easier to consume these cloudevents wherever you are sending the alert, for example if its a consumer based on golang, you can use this: https://github.com/cloudevents/sdk-go/blob/main/samples/http/receiver/main.go
Code change would have to be done here: https://github.com/jertel/elastalert/blob/alt/elastalert/alerts.py#L1884
Would love to get opinions from people who are using Post as alert type.
Beta Was this translation helpful? Give feedback.
All reactions