解决java.net.ConnectException: Connection timed out: connect报错

使用华为OMF开放实验室定向加速解决方案API时,运行TestQosApply类,http://developer.huawei.com/ict/cn/doc/site-omf_development_process_zh/site-omf_development_process_zh.html#1,遇到如下问题

getLocalIp, ip is 192.168.220.199
qosResourceApply jsonBody->{"OTTchargingId":"","ResourceFeatureProperties":[{"FlowProperties":[{"DestinationIpAddress":"172.19.53.108","MaximumUpStreamSpeedRate":1000000,"MaximumDownStreamSpeedRate":4000000,"SourcePort":1000,"Protocol":"UDP","Direction":2,"DestinationPort":2000,"SourceIpAddress":"192.168.220.199"}],"Type":1,"Priority":1,"MinimumUpStreamSpeedRate":200000,"MaximumDownStreamSpeedRate":4000000}],"CPSPID":"","CallBackURL":"","Duration":600,"UserIdentifier":{"MSISDN":"+8613810005678","PublicIP":"192.168.220.199","IP":"192.168.220.199","IMSI":"460030123456789"},"APN":"","ServiceId":"BufferedStreamingVideo"}
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 sun.security.ssl.SSLSocketImpl.connect(Unknown Source)
at sun.security.ssl.BaseSSLSocketImpl.connect(Unknown Source)
at sun.net.NetworkClient.doConnect(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.protocol.https.HttpsClient.<init>(Unknown Source)
at sun.net.www.protocol.https.HttpsClient.New(Unknown Source)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.connect(Unknown Source)
at com.huawei.esdk.qos.service.QosService.qosResourceApply(QosService.java:256)
at com.huawei.esdk.qos.test.TestQosApply.main(TestQosApply.java:15)
TestQosApply result->false

请教各路大神

posted @ 2018-03-26 19:30  Marciaguoguo  阅读(11576)  评论(1编辑  收藏  举报