Add script to send Service XML file to SLS
Close CIPAAS-140
Python script to obtain metrics from Prometheus, generate th XML service file and send it SLS.
The script is designed to be run either in a Cronjob or as a normal application (with option --daemon
). A cronjob might be more appropriate but given the problems in OpenShift 1.5 with the SDN might be trickier.
I've added the values suggested in CIPAAS-140 (with the exception of the haproxy requests per day
, I don't seem to find this in prometheus?)
As it is now, the XML file will always return available
but I can change it if we find good thresholds to assume the service is degrade/unavailable.
Edited by Alberto Rodriguez Peon