Skip to content
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

websocket 压测参数调优 #154

Open
congcongfu opened this issue Oct 24, 2024 · 2 comments
Open

websocket 压测参数调优 #154

congcongfu opened this issue Oct 24, 2024 · 2 comments

Comments

@congcongfu
Copy link

我用这个项目来做websocket 压测,实现的功能是一次调用返回接口,然后服务端同时会给客户端发送一条消息。
压测机配置8C16G 大概 收发qps 各 1500 左右 所有连接都会断掉,请问该怎么调优?

@link1st
Copy link
Owner

link1st commented Oct 24, 2024

以下是调优思路:
1、go 应用程序可以使用 pprof 分析 内存、CPU等瓶颈,针对瓶颈位置的代码进行优化
2、服务器性能分析 网络带宽、文件句柄、CPU 等查看是否达到了瓶颈
3、如果以上都没有达到瓶颈,可以具体分析所有连接都会断掉的错误日志(客户端、服务器的日志),具体分析错误原因

@congcongfu
Copy link
Author

好的,多谢。我按照这个思路来分析下。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants