注册成功过后,推送收不到,程序闪退。

lanfeng0318
7年前 2.7k 0

我按照集成文档,集成的极光推送。我把init放在了登陆成功过后。设置了别名
LOG日志提示别名设置成功,我的别名是一串数字。没有字母。
然后会请求极光的权限,同意后程序会出现闪退,

04-28 11:02:05.838 22881-22881/com.e21cn.im D/JIGUANG-JCore: [PushService] onStartCommand - intent:Intent { act=run.action cmp=com.e21cn.im/cn.jpush.android.service.PushService (has extras) }, pkg:com.e21cn.im, connection:0
04-28 11:02:05.838 22881-23284/com.e21cn.im D/JIGUANG-JCore: [ARunAction]  pkg:com.e21cn.im
04-28 11:02:05.838 22881-22881/com.e21cn.im D/JIGUANG-JCore: [PushService] onStartCommand - intent:Intent { act=cn.jpush.android.intent.INIT cmp=com.e21cn.im/cn.jpush.android.service.PushService (has extras) }, pkg:com.e21cn.im, connection:0
04-28 11:02:05.838 22881-23284/com.e21cn.im D/JIGUANG-JCore: [ARunAction] Bundle[{action=cn.jpush.android.intent.REPORT, report.extra.info=, report=crash_log, sdktype=JCORE}]
04-28 11:02:05.848 22881-23284/com.e21cn.im D/JIGUANG-JCore: [JiguangTcpManager] Action - restartNetworkingClient, pid:22881
04-28 11:02:05.848 22881-22881/com.e21cn.im D/JIGUANG-JCore: [PushService] onStartCommand - intent:Intent { act=run.action cmp=com.e21cn.im/cn.jpush.android.service.PushService (has extras) }, pkg:com.e21cn.im, connection:0
04-28 11:02:05.848 22881-23284/com.e21cn.im D/JIGUANG-JPush: [JPushDataAction] Action - onActionRun
04-28 11:02:05.848 22881-23284/com.e21cn.im D/JIGUANG-JPush: [PushServiceCore] bundle:Bundle[{action=cn.jpush.android.intent.ALIAS_TAGS, seq_id=21789, tags=null, alias=19424, sdktype=JPUSH}]
04-28 11:02:05.848 22881-23284/com.e21cn.im D/JIGUANG-JPush: [PushServiceCore] Action - handleServiceAction - action:cn.jpush.android.intent.ALIAS_TAGS
04-28 11:02:05.848 22881-23307/com.e21cn.im I/JIGUANG-JCore: [NetworkingClient] Begin to run in ConnectingThread - id:1411
04-28 11:02:05.858 22881-23284/com.e21cn.im D/JIGUANG-JPush: [TagAliasHelper] action:setAliasAndTags - alias:19424, tags:null
04-28 11:02:05.868 22881-23284/com.e21cn.im D/JIGUANG-JPush: [JPushRequestHelper] Action - sendJPushRequest, timeout:20000, threadId:1393
04-28 11:02:05.868 22881-22881/com.e21cn.im D/JIGUANG-JCore: [PushService] onStartCommand - intent:Intent { act=sendrequestdata.action cmp=com.e21cn.im/cn.jpush.android.service.PushService (has extras) }, pkg:com.e21cn.im, connection:0
04-28 11:02:05.868 22881-23288/com.e21cn.im D/JIGUANG-JCore: [RequestCacheManager] Action - sendRequestInternal - connection:0, timeout:20000,sdkType:JPUSH, threadId:1396


04-28 11:02:06.748 22881-23297/com.e21cn.im D/AndroidDemos: com.e21cn.im.util.http.io.ClientoutputThread.run:107--->我是正常链接
04-28 11:02:08.738 22881-23307/com.e21cn.im D/JIGUANG-JCore: [ConnectingHelper] To get sis - host:s.jpush.cn, port:19000
04-28 11:02:08.758 22881-23307/com.e21cn.im D/JIGUANG-JCore: [ConnectingHelper] SIS Receiving...
04-28 11:02:08.808 22881-23307/com.e21cn.im I/JIGUANG-JCore: [ConnectingHelper] Get sis info succeed with host: s.jpush.cn
04-28 11:02:08.818 22881-23307/com.e21cn.im D/JIGUANG-JCore: [ConnectingHelper] Open connection with main - ip:118.145.3.78, port:7000
04-28 11:02:08.878 22881-23307/com.e21cn.im I/JIGUANG-JCore: [ConnectingHelper] Succeed to open connection - ip:118.145.3.78, port:7000
04-28 11:02:09.258 22881-23307/com.e21cn.im D/JIGUANG-JCore: [JCommands] Action - receivedCommand - cmd:0
04-28 11:02:09.258 22881-23307/com.e21cn.im I/JIGUANG-JCore: [ConnectingHelper] Register succeed - juid:8741134501, registrationId:13065ffa4e3afcae326, deviceId:null
04-28 11:02:09.268 22881-22881/com.e21cn.im D/JPush: [MyReceiver] onReceive - cn.jpush.android.intent.REGISTRATION, extras: 
                                                     key:cn.jpush.android.APPKEY, value:4c33682958fd239705e2e725
                                                     key:cn.jpush.android.REGISTRATION_ID, value:13065ffa4e3afcae326
04-28 11:02:09.268 22881-22881/com.e21cn.im D/JPush: [MyReceiver] 接收Registration Id : 13065ffa4e3afcae326
04-28 11:02:09.268 22881-22881/com.e21cn.im E/jpush_receiver_send_to_server: com.e21cn.im.resever.Push_Receiver.SendToServer:184--->13065ffa4e3afcae326
04-28 11:02:09.268 22881-23307/com.e21cn.im I/JIGUANG-JCore: [ConnectingHelper] Login with - juid:8741134501, appKey:4c33682958fd239705e2e725, sdkVersion:65794, pushVersion:196613, analyticsVersion:0 ,shareVersion:0, pluginPlatformType:0
04-28 11:02:09.268 22881-22881/com.e21cn.im E/jpush_url: http://kwt.cpta.com.cn/imweb/api/registerPush?accid=15241&appkey=4c33682958fd239705e2e725&jpushid=13065ffa4e3afcae326
04-28 11:02:09.278 22881-22881/com.e21cn.im D/AndroidRuntime: Shutting down VM
04-28 11:02:09.488 22881-23381/com.e21cn.im E/jpush_id_result: {"code":0,"msg":"","data":"注册成功"}
04-28 11:02:09.558 22881-23383/com.e21cn.im D/JIGUANG-JCore: [HttpHelper] status code:200


04-28 11:02:09.558 22881-22881/com.e21cn.im E/AndroidRuntime: FATAL EXCEPTION: main
                                                              Process: com.e21cn.im, PID: 22881
                                                              java.lang.RuntimeException: Unable to start receiver com.e21cn.im.resever.Push_Receiver: java.lang.IllegalStateException: Already Executed
                                                                  at android.app.ActivityThread.handleReceiver(ActivityThread.java:2729)
                                                                  at android.app.ActivityThread.access$1800(ActivityThread.java:167)
                                                                  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1451)
                                                                  at android.os.Handler.dispatchMessage(Handler.java:102)
                                                                  at android.os.Looper.loop(Looper.java:135)
                                                                  at android.app.ActivityThread.main(ActivityThread.java:5401)
                                                                  at java.lang.reflect.Method.invoke(Native Method)
                                                                  at java.lang.reflect.Method.invoke(Method.java:372)
                                                                  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:919)
                                                                  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:714)
                                                               Caused by: java.lang.IllegalStateException: Already Executed
                                                                  at okhttp3.RealCall.execute(RealCall.java:52)
                                                                  at com.e21cn.im.resever.Push_Receiver.SendToServer(Push_Receiver.java:207)
                                                                  at com.e21cn.im.resever.Push_Receiver.onReceive(Push_Receiver.java:54)
                                                                  at android.app.ActivityThread.handleReceiver(ActivityThread.java:2722)
                                                                  at android.app.ActivityThread.access$1800(ActivityThread.java:167) 
                                                                  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1451) 
                                                                  at android.os.Handler.dispatchMessage(Handler.java:102) 
                                                                  at android.os.Looper.loop(Looper.java:135) 
                                                                  at android.app.ActivityThread.main(ActivityThread.java:5401) 
                                                                  at java.lang.reflect.Method.invoke(Native Method) 
                                                                  at java.lang.reflect.Method.invoke(Method.java:372) 
                                                                  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:919) 
                                                                  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:714) 


04-28 11:02:09.598 22881-23307/com.e21cn.im D/JIGUANG-JCore: [JCommands] Action - receivedCommand - cmd:1
04-28 11:02:09.598 22881-23307/com.e21cn.im I/JIGUANG-JCore: [ConnectingHelper] Login succeed - sid:11929, serverTime;1493348528000
04-28 11:02:09.598 22881-23307/com.e21cn.im D/JIGUANG-JCore: [ConnectingHelper] Action - sendServerTimer
04-28 11:02:09.698 22881-23307/com.e21cn.im D/JIGUANG-JCore: [NetworkingClient] Network listening...
04-28 11:02:09.698 22881-23288/com.e21cn.im D/JIGUANG-JCore: [JiguangTcpManager] Action - onLoggedIn - connection:-1198684744
04-28 11:02:09.698 22881-23288/com.e21cn.im D/JIGUANG-JCore: [ConnectingHelper] Action - sendConnectionChanged
04-28 11:02:09.708 22881-23288/com.e21cn.im I/JIGUANG-JCore: [ReportHelper] periodTasks...
04-28 11:02:09.758 22881-23307/com.e21cn.im D/JIGUANG-JCore: [NetworkingClient] Received bytes - len:36, connection:-1198684744, pkg:com.e21cn.im
04-28 11:02:09.758 22881-23307/com.e21cn.im D/JIGUANG-JCore: [NetworkingClient] Network listening...
04-28 11:02:09.938 22881-23288/com.e21cn.im D/JIGUANG-JCore: [HttpHelper] status code:200
04-28 11:02:10.228 22881-23409/com.e21cn.im D/JIGUANG-JCore: [HttpHelper] status code:200
04-28 11:02:11.708 22881-23288/com.e21cn.im D/JIGUANG-JCore: [RequestCacheManager] Action - sendRequestInternal - connection:-1198684744, timeout:0,sdkType:JCORE, threadId:1396

1个回答

热门排序
  • 应该是在init的时候就崩溃了 所以别名设置都没有执行到