Open likuangyu01 opened 1 month ago
check uvicorn example, uvicorn main:app --host 0.0.0.0 --port 80. we have no experience in this
检查 uvicorn 示例,uvicorn main:app --host 0.0.0.0 --port 80。我们在这方面没有经验
If there is no workers parameter, then by default, one process is enabled. However, when I want to open multiple processes to increase concurrency, how should I handle it
This issue is stale because it has been open for 30 days with no activity.
Describe the bug when i use fastapi run the server.py, i want add workers , like this if name == 'main': parser = argparse.ArgumentParser() parser.add_argument('--port', type=int, default=50000) parser.add_argument('--model_dir', type=str, default='iic/CosyVoice-300M', help='local path or modelscope repo id') args = parser.parse_args() cosyvoice = CosyVoice(args.model_dir) uvicorn.run("server:app", port=50000, host="0.0.0.0", workers=4) but when i add workers=4 get errors
INFO: Waiting for child process [920026] INFO: Child process [920026] died 子进程一直没办法启动,这个错误会一直循环,我该如何像别的fastapi项目一样开启多个workers 呢? 感谢回复