我遇到了一个意想不到的问题,即当我
大多数时候运行应用程序时,会打开一个对话框并说“应用程序
连接到服务失败
”参见快照:
虽然在此对话框上按“重新加载”按钮两到三次后,应用程序与 WL 服务器连接,然后应用程序工作正常。但是,如果我杀死 App 然后重新运行它,则会再次出现相同的对话框。
当您在设备上安装后第一次运行应用程序时,它也会出现。
从两个月前开始,我的应用程序运行良好。
我所做的唯一新事情是推送通知。这是
我在应用程序中添加的唯一新功能。
对此有何建议?
- 这个问题的根本原因可能是什么?我怎样才能追踪它?
- 如果我想禁用此对话框,而是
在屏幕上显示自定义消息(警报)。因为此对话框显示
正在运行的服务/WL 服务器 URL。
在控制台中它只显示“应用程序连接到服务失败”
在单击对话框上的详细信息选项时。它显示了 WL 服务器的正确地址。在重新加载三/四次后,它将 App 与服务器连接,然后工作正常,然后一切正常,不显示任何内容。
日志如下:
Apr 15 14:24:51 iPhone myApp[2746] <Warning>: [LOG] ondeviceready event dispatched
Apr 15 14:24:51 iPhone myApp [2746] <Warning>: {
appVersionPref = "1.0";
freeSpace = 13572620288;
wlSkinLoaderChecksum = "(null)";
wlSkinName = default;
}
Apr 15 14:24:51 iPhone myApp [2746] <Warning>: [LOG] Application did not define an i18n messages object, skipping translation.
Apr 15 14:24:51 iPhone myApp [2746] <Warning>: [LOG] wlclient init started
Apr 15 14:24:51 iPhone myApp [2746] <Warning>: [LOG] Read cookies: null
Apr 15 14:24:51 iPhone myApp [2746] <Warning>: [LOG] CookieMgr read cookies: {}
Apr 15 14:24:57 iPhone myApp [2746] <Warning>: [LOG] Connection went Down: Mon Apr 15 2013 14:24:57 GMT+0300 (AST)
Apr 15 14:24:57 iPhone myApp [2746] <Warning>: [ERROR] Client init failed. Connection to the service is not available.
Apr 15 14:25:07 iPhone myApp [2746] <Warning>: [LOG] ondeviceready event dispatched
Apr 15 14:25:07 iPhone myApp [2746] <Warning>: {
appVersionPref = "1.0";
freeSpace = 13572620288;
wlSkinLoaderChecksum = "(null)";
wlSkinName = default;
}
通过单击详细信息:
Apr 15 2013 23:55:17 GMT+0300 (AST)
Apr 15 23:55:17 iPhone myApp[3116] <Warning>: [ERROR] Client init failed. Connection to the service is not available.
Apr 15 23:55:19 iPhone myApp[3116] <Warning>: WLReachability Flag Status: -R -----l- networkStatusForFlags
Apr 15 23:55:59 iPhone kernel[0] <Debug>: launchd[3120] Builtin profile: MobileSafari (sandbox)
Apr 15 23:56:02 iPhone kernel[0] <Debug>: launchd[3121] Builtin profile: syncdefaultsd (sandbox)
Apr 15 23:56:21 iPhone myApp[3116] <Warning>: Copied text: 'App Diagnostics
Time : Mon Apr 15 2013 23:55:19 GMT+0300 (AST)
Application Name : myApp
Application Version : 1.0
Service URL : https://www.mydomain.com.bh:443/AppProject/apps/services/api/myApp/iphone/
Device Platform : iPhone
Device Version : 6.1
Screen Resolution : 320x480
Airplane Mode : Not available
Using Network : WIFI
Wifi Name : Not available
Mobile Network Type : Not available
Carrier Name : Not available
IP Address : 192.168.109.101
Error Code : UNRESPONSIVE_HOST
Error Message : Connection to the service is not available.
HTTP Status :