Allow specifying multiple mwmbr thresholds
This allows specifying multiple mwmbr thresholds per service.
This is illustrated by converting the deployment thresholds to use this.
Thresholds on a service can be specified using the otherThresholds
key. Adding a new threshold will start recording new health metrics
under the name gitlab_<threshold name>_health
.
For example: specifying the a new threshold as follows:
otherThresholds: {
deployment: {
apdexScore: 0.998,
errorRatio: 0.9999,
},
},
Wil result in the following recordings:
-
The specified thresholds: Scalars with the specified thresholds
slo:max:deployment:gitlab_service_errors:ratio
slo:min:deployment:gitlab_service_apdex:ratio
-
The health status: Vectors returning 1 if the SLI (error or apdex) meets the threshold, or 0 if it doesn't.
gitlab_deployment_health:service:errors
gitlab_deployment_health:service:apdex
-
Aggregated health status: Aggregates both SLIs into a health status for the service, or an entire stage.
gitlab_deployment_health:service
gitlab_deployment_health:stage
This is the groundwork for gitlab-com/gl-infra/mstaff#17 (comment 495326325) after the discussion in !3201 (comment 501271861).