SoapUI:ConnectException:连接超时:
我尝试通过 REST 发送请求。 使用 Firefox Rest-Client 时我得到成功响应, 但在 SoapUI 中我得到下面附加的异常。 如何解决这个问题? 谢谢。
java.net.ConnectException:连接 超时:连接于 java.net.PlainSocketImpl.socketConnect(本机 方法)在 java.net.PlainSocketImpl.doConnect(未知 来源)于 java.net.PlainSocketImpl.connectToAddress(未知 来源)于 java.net.PlainSocketImpl.connect(未知 来源)于 java.net.SocksSocketImpl.connect(未知 来源)于 java.net.Socket.connect(未知 来源)于 java.net.Socket.connect(未知 来源)于 java.net.Socket。(来源不明) 在 java.net.Socket 处。(未知 来源)于 org.apache.commons.httpclient.protocol.DefaultProtocolSocketFactory.createSocket(DefaultProtocolSocketFactory.java:80) 在 org.apache.commons.httpclient.protocol.DefaultProtocolSocketFactory.createSocket(DefaultProtocolSocketFactory.java:122) 在 org.apache.commons.httpclient.HttpConnection.open(HttpConnection.java:707) 在 com.eviware.soapui.impl.wsdl.support.http.SoapUIMultiThreadedHttpConnectionManager$HttpConnectionAdapter.open(SoapUIMultiThreadedHttpConnectionManager.java:1637) 在 org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:387) 在 org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171) 在 org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397) 在 com.eviware.soapui.impl.wsdl.submit.transports.http.HttpClientRequestTransport.sendRequest(HttpClientRequestTransport.java:202) 在 com.eviware.soapui.impl.wsdl.WsdlSubmit.run(WsdlSubmit.java:123) 在 java.util.concurrent.Executors$RunnableAdapter.call(未知 来源)于 java.util.concurrent.FutureTask$Sync.innerRun(未知 来源)于 java.util.concurrent.FutureTask.run(未知 来源)于 java.util.concurrent.ThreadPoolExecutor$Worker.runTask(未知 来源)于 java.util.concurrent.ThreadPoolExecutor$Worker.run(未知 来源)于 java.lang.Thread.run(来源不明)
i try to send request via REST.
I get success response when using firefox rest-client,
but in SoapUI i get exception attached below.
How to resolve this issue?
Thanks.
java.net.ConnectException: Connection
timed out: connect at
java.net.PlainSocketImpl.socketConnect(Native
Method) at
java.net.PlainSocketImpl.doConnect(Unknown
Source) at
java.net.PlainSocketImpl.connectToAddress(Unknown
Source) at
java.net.PlainSocketImpl.connect(Unknown
Source) at
java.net.SocksSocketImpl.connect(Unknown
Source) at
java.net.Socket.connect(Unknown
Source) at
java.net.Socket.connect(Unknown
Source) at
java.net.Socket.(Unknown Source)
at java.net.Socket.(Unknown
Source) at
org.apache.commons.httpclient.protocol.DefaultProtocolSocketFactory.createSocket(DefaultProtocolSocketFactory.java:80)
at
org.apache.commons.httpclient.protocol.DefaultProtocolSocketFactory.createSocket(DefaultProtocolSocketFactory.java:122)
at
org.apache.commons.httpclient.HttpConnection.open(HttpConnection.java:707)
at
com.eviware.soapui.impl.wsdl.support.http.SoapUIMultiThreadedHttpConnectionManager$HttpConnectionAdapter.open(SoapUIMultiThreadedHttpConnectionManager.java:1637)
at
org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:387)
at
org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171)
at
org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397)
at
com.eviware.soapui.impl.wsdl.submit.transports.http.HttpClientRequestTransport.sendRequest(HttpClientRequestTransport.java:202)
at
com.eviware.soapui.impl.wsdl.WsdlSubmit.run(WsdlSubmit.java:123)
at
java.util.concurrent.Executors$RunnableAdapter.call(Unknown
Source) at
java.util.concurrent.FutureTask$Sync.innerRun(Unknown
Source) at
java.util.concurrent.FutureTask.run(Unknown
Source) at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown
Source) at
java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown
Source) at
java.lang.Thread.run(Unknown Source)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
默认套接字超时设置为 60000 毫秒。
您可以更改它:
Default socket timeout is set to 60000 milliseconds.
You can change it:
您也可以将该值设置为 0,这样就不会超时。
使用 SoapUI 4.5.0 进行测试
You can also set the value to 0 and then it doesn't time out.
Tested it with SoapUI 4.5.0
您还可以为请求设置超时,它位于左下
请求属性
,这对我有帮助(SoapUI 5.4.0)You can also set timeout for your request, it's on left bottom
Request properties
, that helped me (SoapUI 5.4.0)我会尝试在 SoapUI 首选项中调整套接字超时。 SoapUI 的标准超时为 60000 毫秒。我会尝试将其放大,看看您是否有同样的问题。这之前已经为我自己解决了超时问题。
您还可以直接在soapui-settings.xml 中编辑此设置。
如果这没有帮助,请尝试在 eviware 论坛。
I would try adjusting the socket timeout in SoapUI preferences. SoapUI has a standard timeout of 60000 milliseconds. I would try making that much larger to see if you have the same issue. This has fixed a timeout issue for myself before.
You can also edit this setting directly in the soapui-settings.xml
If this doesn't help, try asking on the eviware forum.
除了调整超时之外,如果此问题仍然存在,则可能是因为 SoapUI 所需的
插件很少未加载
。因为这些插件存在于其他需要权限访问的地方。如果您检查日志,您可以找到此跟踪:
直接从 bin 启动 SoapUI 时不会出现问题
另外您也可以
使用管理权限运行。
Apart from adjusting timeouts, if this issue still persists then it could be because few of the
plugins needed by SoapUI are not loaded
. Because these plugins are present in some other place that require permission to access.If u check your logs u can find this trace :
The
problem does not occur when starting the SoapUI directly from bin
Also you can
run with Administrative privileges.