error: can't start new thread

前端 未结 8 1373
天涯浪人
天涯浪人 2020-12-01 12:31

I have a site that runs with follow configuration:

Django + mod-wsgi + apache

In one of user\'s request, I send another HTTP request to another service, and

8条回答
  •  再見小時候
    2020-12-01 12:53

    If you are using a ThreadPoolExecutor, the problem may be that your max_workers is higher than the threads allowed by your OS.

    It seems that the executor keeps the information of the last executed threads in the process table, even if the threads are already done. This means that when your application has been running for a long time, eventually it will register in the process table as many threads as ThreadPoolExecutor.max_workers

提交回复
热议问题