google / google/slo-generator

bad API error message when using a not existing backend

Open
#294 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
564
Forks
88
PR merge metrics
No merged PRs in 30d

Description

When you use slo-generator in API mode, if you try to compute an SLI with a unknown backend (i mean not specified from the shared configuration), error message from the API is not clear :

Call :
```
curl -X POST -H "Content-Type: text/x-yaml" --data-binary @sli_get-organization_availability.yaml -H "Authorization: Bearer $(gcloud auth print-identity-token)" https://slo-generator-xxxxxxxx-ew.a.run.app
```

Answer:
```
Service Unavailable%
```

Log seen from SLO Generator instance:
```
ERROR - Backend "cloud_monitoring/xxxxxxx" not found in config. Exiting.
```

maybe the error is not well catched ?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.