fix(接口测试): tcp请求导出以及转性能测试时className不再使用我们覆盖了的类

--bug=1031030 --user=宋天阳 【性能测试】github#26844,TCP协议性能测试报告与JMeter界面的聚合数据不一致
https://www.tapd.cn/55049933/s/1426786
This commit is contained in:
song-tianyang 2023-10-16 18:20:12 +08:00 committed by 建国
parent 4de8d2a389
commit 77b34eefd9
1 changed files with 6 additions and 1 deletions

View File

@ -263,7 +263,12 @@ public class MsTCPSampler extends MsTestElement {
tcpSampler.setClassname(this.getClassname());
}
if (StringUtils.equals("TCPClientImpl", this.getClassname())) {
tcpSampler.setClassname(MsTCPClientImpl.class.getCanonicalName());
if (config.isOperating()) {
//导出时className不转换MsTCPClientImpl 这个类在性能测试时tps会变得很低
tcpSampler.setClassname(TCPSampler.class.getName());
} else {
tcpSampler.setClassname(MsTCPClientImpl.class.getCanonicalName());
}
}
tcpSampler.setCharset(this.getConnectEncoding());
tcpSampler.setServer(this.getServer());