Skip to content

建议更新文档: 上传大文件的坑 #394

@muxik

Description

@muxik

使用think-swoole 在上传大文件的时候 无响应 多上传几次会导致nginx 502

在nginx 和 php.ini 配置正常的情况下需要注意

Swoole 的默认 package_max_length 通常为 2M,如果文件超过这个大小,可能会被直接丢弃。

'http' => [
...
'options' => [
'package_max_length' => 50 * 1024 * 1024
],
],

增加 package_max_length 可以解决此问题 ,建议官方更新 options 相关的文档

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions