fix: Swoole 加 max_request 防内存泄漏导致状态异常
- worker/task 每处理 10000 请求自动重生,释放内存 - 解决长时间运行后龙虎等游戏偶发状态异常的问题
This commit is contained in:
@@ -17,6 +17,8 @@ return [
|
||||
'reactor_num' => swoole_cpu_num(),
|
||||
'worker_num' => swoole_cpu_num(),
|
||||
'task_worker_num' => swoole_cpu_num(),
|
||||
'max_request' => 10000,
|
||||
'max_task_request' => 10000,
|
||||
'enable_static_handler' => true,
|
||||
'document_root' => root_path('public'),
|
||||
'package_max_length' => 20 * 1024 * 1024,
|
||||
|
||||
Reference in New Issue
Block a user