51Testing软件测试论坛

标题: jmeter运行时报错,大神们能帮我找找原因么? [打印本页]

作者: vampire0925    时间: 2017-5-24 14:11
标题: jmeter运行时报错,大神们能帮我找找原因么?
Thread Name: 线程组 1-10
Sample Start: 1970-01-01 08:00:00 CST
Load time: 0
Connect Time: 0
Latency: 0
Size in bytes: 708
Sent bytes:0
Headers size in bytes: 0
Body size in bytes: 708
Sample Count: 1
Error Count: 1
Data type ("text"|"bin"|""): text
Response code: Non HTTP response code: java.net.MalformedURLException
Response message: Non HTTP response message: unknown protocol: baidu.com

Response headers:


HTTPSampleResult fields:
ContentType:
DataEncoding: null

响应数据
java.net.MalformedURLException: unknown protocol: baidu.com
        at java.net.URL.<init>(URL.java:421)
        at java.net.URL.<init>(URL.java:310)
        at org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.getUrl(HTTPSamplerBase.java:1008)
        at org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1189)
        at org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1178)
        at org.apache.jmeter.threads.JMeterThread.executeSamplePackage(JMeterThread.java:491)
        at org.apache.jmeter.threads.JMeterThread.processSampler(JMeterThread.java:425)
        at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:254)
        at java.lang.Thread.run(Thread.java:745)

线程数配置10
http请求页面中
协议:   baidu.com
端口号:   80
方法:   get
路径:  /
timeouts:    200
其他都是默认了 但是运行一直报错
也检查了运行环境配置  都正常


我是一个新手 ,看不出问题
请哪位大神帮我看看哪里出错了  

谢谢了!  拜托了,大神们!

作者: 一抹红尘    时间: 2017-5-25 12:41
1、“java.net.MalformedURLException: unknown protocol: baidu.com”这是报错的原因,未知的协议
2、“协议:   baidu.com” 协议怎能选择这个呢,baidu.com是url

作者: vampire0925    时间: 2017-6-16 14:47
那请问我这个怎么改啊  我想用百度作为测试网站?谢谢了
作者: nicor_71ang    时间: 2018-7-20 15:51
不知道这个时候给你还合不合适:
https://stackoverflow.com/questi ... de-non-htt/43533171

protocal[http]: 输入: http
Server Name or IP : 输入: url





欢迎光临 51Testing软件测试论坛 (http://bbs.51testing.com/) Powered by Discuz! X3.2