error: can't start new thread

前端 未结 8 1375
天涯浪人
天涯浪人 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:49

    If you are tying to set timeout why don't you use urllib2.

    0 讨论(0)
  • 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

    0 讨论(0)
提交回复
热议问题