jeudi 26 octobre 2023

dev hub / plateform engineering : backstage.io

 https://backstage.io/ 

from spotify, released open source.

"An open platform for building developer portals

Powered by a centralized software catalog, Backstage restores order to your infrastructure and enables your product teams to ship high-quality code quickly — without compromising autonomy."




https://backstage.io/plugins/


Red Hat developer-hub is a backstage implementation :

https://developers.redhat.com/articles/2023/05/23/developers-guide-red-hat-developer-hub-and-janus#

https://developers.redhat.com/products/plugins-for-backstage/overview

mardi 17 octobre 2023

prometheus, grafana, alertmanager: number of alerts

 prometheus alerts counts


from : https://jaanhio.me/blog/visualizing-alerts-metrics-grafana/ + https://community.grafana.com/t/how-to-get-the-time-range-selected-on-the-dashboard-into-a-variable/2868/3

(sum by (alertname) (changes(ALERTS_FOR_STATE[$__range]) AND ignoring(alertstate) max_over_time(ALERTS{alertstate="firing"}[$__range])) + (count by (alertname) (changes(ALERTS_FOR_STATE[$__range]) AND ignoring(alertstate) max_over_time(ALERTS{alertstate="firing"}[$__range])) * 1))


Then use a grafana panel as "Gauge" with the following options :

* Value options: show calculate, Last *

* Orientation = horizontal, and 



Number of alerts by alert name of the last 2 months

PromQL = sum by(alertname) (changes(ALERTS_FOR_STATE[65d]))



Number of alerts by instance over the last 2 months

PromQL = sum by(instance_name) (changes(ALERTS_FOR_STATE[65d]))