有什么方法可以使用Web套接字协议生成脚本吗?
我想为我的一个项目进行性能测试。该项目具有多种协议。像网页http / html和网页套接字。 如何生成Web套接字协议的脚本。
如果我尝试生成脚本,则会出现错误
2019-03-27 16:49:24,712 WARN o.a.j.p.h.p.Proxy: [58109] Unable to negotiate SSL transaction, no keystore?
2019-03-27 16:49:24,728 ERROR o.a.j.p.h.p.Proxy: [58109] Exception when processing sample
java.io.IOException: Unable to negotiate SSL transaction, no keystore?
at org.apache.jmeter.protocol.http.proxy.Proxy.startSSL(Proxy.java:446) ~[ApacheJMeter_http.jar:4.0 r1823414]
at org.apache.jmeter.protocol.http.proxy.Proxy.run(Proxy.java:194) [ApacheJMeter_http.jar:4.0 r1823414]
2019-03-27 16:49:24,728 WARN o.a.j.p.h.p.Proxy: [58109] Exception while writing error
java.net.SocketException: Software caused connection abort: socket write error
at java.net.SocketOutputStream.socketWrite0(Native Method) ~[?:1.8.0_191]
at java.net.SocketOutputStream.socketWrite(Unknown Source) ~[?:1.8.0_191]
at java.net.SocketOutputStream.write(Unknown Source) ~[?:1.8.0_191]
at java.io.DataOutputStream.writeBytes(Unknown Source) ~[?:1.8.0_191]
at org.apache.jmeter.protocol.http.proxy.Proxy.writeErrorToClient(Proxy.java:561) [ApacheJMeter_http.jar:4.0 r1823414]
at org.apache.jmeter.protocol.http.proxy.Proxy.run(Proxy.java:258) [ApacheJMeter_http.jar:4.0 r1823414]
2019-03-27 16:49:24,728 INFO o.a.j.p.h.p.ProxyControl: [58110] Creating entry web.qa.np.1shift.io in D:\apache-jmeter-4.0\apache-jmeter-4.0\bin\proxyserver.jks
2019-03-27 16:49:25,566 ERROR o.a.j.p.h.p.Proxy: [58110] Problem with keystore
java.io.IOException: >> keytool error: java.lang.RuntimeException: java.io.IOException: DNSName components must begin with a letter
答案 0 :(得分:0)
根据RFC-1034,域名必须以字母开头,因此,我的期望是您正在尝试记录IP地址或以数字或怪异开头的域名。
有以下解决方法:
hosts
file来为您要记录的主机提供一个别名,该别名不会与上述RFC-1034冲突无论如何,我认为您无法记录WebSocket协议,尽管它是基于HTTP的,但是它是JMeter的HTTP Request采样器无法处理的另一种野兽,您将不得不模仿WebSocket JMeter WebSocket Samplers by Peter Doornbosch
获得流量