-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
运行一段时间后性能开始降低 #34
Comments
你跑的是哪个模式,以及业务代码用了哪几个facade? |
SwooleFastCGI,Facade:太多了,大部分都在用。 max_request默认就是2000哇 |
貌似Response里面header和cookie有问题呢,无限追加,没有清理。 |
回滚版本到0.2.8后,未出现这问题。 |
我自行测试未能重现,\Laravoole\Response在SwooleFastCGI下不会创建实例,我自己跑循环请求fastcgi也没问题 |
应该是手动处理max_request带来的问题 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi garveen,
最近升级laravoole后,发现运行一段时间后,性能开始降低,耗时从最初的60ms增加的2s,每次restart后才恢复正常,但好景不长。
laravoole 5.1, swoole 1.9.6
一张请求耗时图,其中接近18点时进行了restart。

我首先考虑到的是内存问题,然后分别在restart后和出问题时得到了内存占用情况。

刚开始运行时的内存占用:
性能降低时的内存占用:

确实内存增量很大,然后开始检查业务代码有没有内存泄漏隐患,但没发现
swoole内存管理
所以考虑是不是laravoole这层有问题,比如在clean中需要unset清理一些大数组、容器、实例。
请协助一起看看。
谢谢!
The text was updated successfully, but these errors were encountered: