为什么极光推送api 推送失败

jpush
标签: #<Tag:0x00007fb84dad5e00>

(feel) #1

这是我报错的代码

jpush Send repush 2 returned false
cn.jiguang.common.resp.APIConnectionException: connect timed out. 
Connect to JPush Server timed out, and already retried some times. 
Please ensure your internet connection is ok. 
If the problem persists, please let us know at support@jpush.cn.
	at cn.jiguang.common.connection.NativeHttpClient.doRequest(NativeHttpClient.java:107)
	at cn.jiguang.common.connection.NativeHttpClient.sendPost(NativeHttpClient.java:86)
	at cn.jpush.api.push.PushClient.sendPush(PushClient.java:160)
	at cn.jpush.api.JPushClient.sendPush(JPushClient.java:194)
	at com.jpush.utlis.pushUtlis.sendPushMessage(pushUtlis.java:115)
	at com.kimleysoft.tmcclient.ReceiveTmcClient$1.onMessage(ReceiveTmcClient.java:66)
	at com.eprint.api.internal.tmc.TmcHandler.onMessage(TmcHandler.java:77)
	at org.apache.activemq.ActiveMQMessageConsumer.dispatch(ActiveMQMessageConsumer.java:1298)
	at org.apache.activemq.ActiveMQSessionExecutor.dispatch(ActiveMQSessionExecutor.java:131)
	at org.apache.activemq.ActiveMQSessionExecutor.iterate(ActiveMQSessionExecutor.java:202)
	at org.apache.activemq.thread.PooledTaskRunner.runTask(PooledTaskRunner.java:122)
	at org.apache.activemq.thread.PooledTaskRunner$1.run(PooledTaskRunner.java:43)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
Caused by: java.net.SocketTimeoutException: connect timed out
	at java.net.PlainSocketImpl.socketConnect(Native Method)
	at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
	at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
	at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
	at java.net.Socket.connect(Socket.java:589)
	at sun.security.ssl.SSLSocketImpl.connect(SSLSocketImpl.java:673)
	at sun.net.NetworkClient.doConnect(NetworkClient.java:175)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
	at sun.net.www.protocol.https.HttpsClient.<init>(HttpsClient.java:264)
	at sun.net.www.protocol.https.HttpsClient.New(HttpsClient.java:367)
	at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient(AbstractDelegateHttpsURLConnection.java:191)
	at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1138)
	at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1032)
	at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:177)
	at sun.net.www.protocol.http.HttpURLConnection.getOutputStream0(HttpURLConnection.java:1316)
	at sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:1291)
	at sun.net.www.protocol.https.HttpsURLConnectionImpl.getOutputStream(HttpsURLConnectionImpl.java:250)
	at cn.jiguang.common.connection.NativeHttpClient._doRequest(NativeHttpClient.java:161)
	at cn.jiguang.common.connection.NativeHttpClient.doRequest(NativeHttpClient.java:99)
	... 14 more

但是在推送历史的api中没有发现推送记录 然服务是可以联网的,是不是极光推送有问题?

PushPayload payload5 = buildPushObject_all_tag_alert(alias,message);
PushResult result = jPushClient.sendPush(payload);//到这步就出问题了就是老是抱以上的错误?指定什么原因?从2018-10-30 01:30:20以后 就开始在推送历史api 中收不到消息


#2

超时问题,请检查服务端网络设置


(feel) #3

网络设置没问题。https://api.jpush.cn/v3/push/xxxx 这条连接就是推送官网的请求接口 但是就是出现 了超时问题


#4

去检查你们的端口,防火墙相关的。根据链接说明给出 ping 等的结果。
https://api.jpush.cn

我们这个接口现在使用是没有问题的,使用 curl Postman 测试均正常