我是JMeter的新手,所以我正在研究here教程,其中它指导我设置具有1个线程,1个加速周期和1个循环计数的基本请求。
我尝试访问指南中定义的网页,网址为www.tutorialspoint.com。
但是我的结果树每次都向我显示错误,如下所示:
Response code: Non HTTP response code: org.apache.http.conn.HttpHostConnectException
Response message: Non HTTP response message: Connect to www.tutorialspoint.com:80 [www.tutorialspoint.com/117.18.237.42] failed: Connection timed out: connect
当我在Fiddler上跟踪流量时,我从JMeter运行测试时看不到任何情况,这表明我什至没有到达网站。
不确定从这里开始我要去哪里。如果有帮助,我会在下面的请求和响应中添加更多信息。
采样结果:
Thread Name: Users 1-1
Sample Start: 2019-07-18 10:24:32 AWST
Load time: 21130
Connect Time: 21127
Latency: 0
Size in bytes: 2746
Sent bytes:0
Headers size in bytes: 0
Body size in bytes: 2746
Sample Count: 1
Error Count: 1
Data type ("text"|"bin"|""): text
Response code: Non HTTP response code: org.apache.http.conn.HttpHostConnectException
Response message: Non HTTP response message: Connect to www.tutorialspoint.com:80 [www.tutorialspoint.com/117.18.237.42] failed: Connection timed out: connect
HTTPSampleResult fields:
ContentType:
DataEncoding: null
请求标头:
Connection: keep-alive
Host: www.tutorialspoint.com
User-Agent: Apache-HttpClient/4.5.7 (Java/1.8.0_71)
请求正文:
GET http://www.tutorialspoint.com/
GET data:
[no cookies]
响应正文:
org.apache.http.conn.HttpHostConnectException: Connect to www.tutorialspoint.com:80 [www.tutorialspoint.com/117.18.237.42] failed: Connection timed out: connect
at org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:156)
at org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl$JMeterDefaultHttpClientConnectionOperator.connect(HTTPHC4Impl.java:336)
at org.apache.http.impl.conn.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:374)
at org.apache.http.impl.execchain.MainClientExec.establishRoute(MainClientExec.java:393)
at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:236)
at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:185)
at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:89)
at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110)
at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:185)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:83)
at org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.executeRequest(HTTPHC4Impl.java:843)
at org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.sample(HTTPHC4Impl.java:574)
at org.apache.jmeter.protocol.http.sampler.HTTPSamplerProxy.sample(HTTPSamplerProxy.java:67)
at org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1231)
at org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1220)
at org.apache.jmeter.threads.JMeterThread.doSampling(JMeterThread.java:622)
at org.apache.jmeter.threads.JMeterThread.executeSamplePackage(JMeterThread.java:546)
at org.apache.jmeter.threads.JMeterThread.processSampler(JMeterThread.java:486)
at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:253)
at java.lang.Thread.run(Unknown Source)
Caused by: java.net.ConnectException: Connection timed out: connect
at java.net.DualStackPlainSocketImpl.connect0(Native Method)
at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source)
at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source)
at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source)
at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at org.apache.http.conn.socket.PlainConnectionSocketFactory.connectSocket(PlainConnectionSocketFactory.java:75)
at org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:142)
... 19 more