Closed ldynia closed 2 years ago
hi, this seems like there is a problem with your code. Can you send your service definition in here?
@aarnphm I have updated issued with detailed step-by-step instructions how to reproduce this bug. Please test it, and you will see that you will arrive to the same conclusions.
@aarnphm can I get any update ?
Hi ! is there any resolution regarding this issue? Is this going to be fixed @parano ?
Thank you for reporting the issue @ldynia @smiraldr - this is likely due to an issue with python prometheus client's multi process support. In the upcoming BentoML 1.0, we have revamped that implementation and made sure metrics are collected correctly across multiple workers https://github.com/bentoml/BentoML/issues/2163. cc @bojiang
Bug
Improper error handling in BentoML application. Invalid request courses, 400 and 500 error responses that are never send to
/metrics
endpoint.To Reproduce
Below steps where inspired by following BentoML's Hello World example.
1. Install OS dependencies & clone project
2. Setup virtual environment and install dependencies
3. Create BentoService
4. Spin up containers
5. Test successfully 500 errors.
Execute CURL command x3 times.
Visit http://localhost:5000/ click
/metrics
>Try it out
>Execute
. You will see that CURL request appears 3.0 times in/metics
log as 500 error.6. Test unsuccessfully 500 errors.
Execute CURL command x4 time.
Visit http://localhost:5000/ click
/metrics
>Try it out
>Execute
. You will see that CURL request appears 4.0 times in/metics
log as 200 success !!!Investigate log of
bentoml-classifier
container. You will see unhandled exception!Expected behaviour
Log messages with 500 error should be sent to
/metrics
7.0 times. That is not the case!Environment: