Question

I'm using Flask where i load some pre-trained machine learning models once. I'm also using Gunicorn usually with 2 or 4 workers to handle parallel requests.

Every request contains some texts that i want to analyze.

I'll explain my problem with a example: My Flask server with Gunicorn and 2 workers is up and loads my models once for every worker. Then i send two parallel requests. The first will run analysis on the 1st worker with 500 texts and the second on the 2nd worker with 2000 texts. The problem is that the second request will stop the analysis after some period of time and reload the models for this worker.

Does Gunicorn contains a default worker timeout and how it can be solved?

No correct solution

Licensed under: CC-BY-SA with attribution
Not affiliated with datascience.stackexchange
scroll top