-
Notifications
You must be signed in to change notification settings - Fork 4
Socket API 性能测试
gc87 edited this page Oct 14, 2018
·
4 revisions
-
启动jmeter,点击菜单:Optins>Plugins Manager,在打开的插件管理器中安装一下插件:
- TCP Protocol Support
- 3 Basic Graphs
- 5 Additional Graphs
- Composite Timeline Graph
- Distribution/Percentile Graphs
- Filter Results Tool
- Synthesis Report
-
克隆DBPMsg项目到本地。
git clone [email protected]:FissionAndFusion/DBPMsg.git
-
使用jmeter打开DBPMsg中的dbp-lws.jmx。
-
使用JetBrians IDEA打开DBPMsg/DbpLws下的工程,单击菜单Build>Build Artifacts生成DbpLws.jar,或者直接下载在jdk1.8.0_192环境下编译的jar包。
-
在Test Plan中设置jmeter加载DbpLws.jar的路径,如图:
-
由于jmeter TCP测试模块限制,需修改FnFnCoreWallet源码,在CDbpClient类的WriteMessageToSendStream()函数中加入以下代码:
char c = '\n'; ssSend.Write((char *)&c, sizeof(char));
-
重新编译FnFnCoreWallet,并运行multiverse进程。
-
在Test Plan中设置multiverse的测试地址和端口:
-
设置启动线程数目,jmeter中每用户将单独使用一线程,并在该线程中循环收发数据:
-
点击工具栏的播放按钮即可进行测试、点击扫帚按钮可以清除上一次测试结果。
Home | Copyright © 2017-2019 FissionAndFusion