我在Android的混合Mobile First应用程序中工作,在我调用适配器后,注册的回调函数永远不会被调用。这是日志,我只能看到我的应用程序取消注册推送订阅。
05-06 11:18:16.429: D/mali_winsys(4021): new_window_surface returns 0x3000
05-06 11:18:16.429: D/ProgressBar(4021): updateDrawableBounds: left = 0
05-06 11:18:16.429: D/ProgressBar(4021): updateDrawableBounds: top = 0
05-06 11:18:16.429: D/ProgressBar(4021): updateDrawableBounds: right = 144
05-06 11:18:16.429: D/ProgressBar(4021): updateDrawableBounds: bottom = 144
05-06 11:18:16.479: D/NONE(4021): Request [/apps/services/api/appname/android/query]
05-06 11:18:16.574: D/HttpPostRequestSender(4021): WLHybridRequestSender.run in WLHybridRequestSender.java:47 :: Sending request https://domain/appproject/apps/services/api/appname/android/query
05-06 11:18:16.574: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):getSBService() is false
05-06 11:18:16.574: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):SMARTBONDING_ENABLED is false
05-06 11:18:16.574: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):Resquest instance of HttpUriRequesttrue
05-06 11:18:16.574: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):determineRoute Local address : null
05-06 11:18:16.579: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):Inside DefaultClientConnectionOperator.openConnection()
05-06 11:18:16.579: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):start to get IP for host domain at time 1430921896581
05-06 11:18:16.579: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):finish to get IP for host domain at time 1430921896583, result number 1
05-06 11:18:16.579: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):DefaultClientConnectionOperator.openConnection()InetAddress.getAllByName length:1
05-06 11:18:16.614: D/SoftKeyboardDetect(4021): Ignore this event
05-06 11:18:16.629: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):DefaultClientConnectionOperator.openConnection() connsock Socket[address=/ip,port=443,localPort=35222]
05-06 11:18:16.714: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):Servers selected Ip address is : ip
05-06 11:18:17.004: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):HttpClientParams.isRedirecting(params) : true
05-06 11:18:17.004: I/System.out(4021): pool-5-thread-2(ApacheHTTPLog):this.redirectHandler.isRedirectRequested(response, context) : false
05-06 11:18:17.004: I/System.out(4021): pool-5-thread-2 calls detatch()
05-06 11:18:17.044: D/NONE(4021): Clearing notification subscriptions.
05-06 11:18:17.049: D/NONE(4021): Clearing tag notification subscriptions.
05-06 11:18:17.054: D/NONE(4021): Send new server notification token id.
05-06 11:18:17.059: D/GCMRegistrar(4021): resetting backoff for com.appname
05-06 11:18:17.059: V/GCMRegistrar(4021): Registering app com.appname of senders 15237827500
05-06 11:18:17.059: D/NONE(4021): Updating tag notification subscriptions.
05-06 11:18:17.069: D/CordovaLog(4021): file:///android_asset/www/default/worklight/worklight.js: Line 5688 : No matching configurations found from the server. Defaulting to local configuration
05-06 11:18:17.069: I/chromium(4021): [INFO:CONSOLE(5688)] "No matching configurations found from the server. Defaulting to local configuration", source: file:///android_asset/www/default/worklight/worklight.js (5688)
05-06 11:18:17.074: D/NONE(4021): response [/apps/services/api/appname/android/query] success: /*-secure-
05-06 11:18:17.074: D/NONE(4021): {"statusCode":200,"errors":[],"isSuccessful":true,"Envelope":{"Body":{"Clearing_MobileResponse":{"Clearing_MobileResult":{"schema":{"id":"NewDataSet","element":{"complexType":{"choice":{"element":{"complexType":{"sequence":{"element":[{"name":"PROCESANDO_SOLICITUD","type":"xs:string","minOccurs":"0"},{"name":"ERROR","type":"xs:int","minOccurs":"0"}]}},"name":"TablaInfo"},"maxOccurs":"unbounded","minOccurs":"0"}},"MainDataTable":"TablaInfo","name":"NewDataSet","IsDataSet":"true","UseCurrentLocale":"true"},"msdata":"urn:schemas-microsoft-com:xml-msdata","xs":"http:\/\/www.w3.org\/2001\/XMLSchema","xmlns":""},"diffgram":{"msdata":"urn:schemas-microsoft-com:xml-msdata","DocumentElement":{"TablaInfo":{"id":"TablaInfo1","hasChanges":"inserted","PROCESANDO_SOLICITUD":"OK","ERROR":"0","rowOrder":"0"},"xmlns":""},"diffgr":"urn:schemas-microsoft-com:xml-diffgram-v1"}},"xmlns":"http:\/\/sa-webservices\/"}},"xsd":"http:\/\/www.w3.org\/2001\/XMLSchema","soap":"http:\/\/www.w3.org\/2003\/05\/soap-envelope","xsi":"http:\/\/www.w3.org\/2001\/XMLSchema-instance"},"statusReason":"OK","WL-Authentication-Success":{"wl_anonymousUserRealm":{"userId":"09f4f163-c5ee-40d0-964a-4a15060abe42","attributes":{},"isUserAuthenticated":1,"displayName":"09f4f163-c5ee-40d0-964a-4a15060abe42","deviceId":"09f4f163-c5ee-40d0-964a-4a15060abe42"}},"notificationSubscriptionState":{"tags":["Push.ALL"],"eventSources":[],"token":"APA91bFNWYtZp2DTdK4rMLrIKzvktSp64lFK3__AM-...","credentials":"15237827348"},"responseHeaders":{"X-AspNet-Version":"4.0.30319","Date":"Wed, 06 May 2015 14:18:49 GMT","Content-Length":"1316","Content-Type":"application\/soap+xml; charset=utf-8","Server":"Microsoft-IIS\/6.0","X-Powered-By":"ASP.NET","Cache-Control":"private, max-age=0"},"warnings":[],"responseTime":108,"totalTime":110,"info":[]}*/
05-06 11:18:17.099: E/ViewRootImpl(4021): sendUserActionEvent() mView == null
05-06 11:18:17.154: D/mali_winsys(4021): new_window_surface returns 0x3000
05-06 11:18:17.519: V/GCMBroadcastReceiver(4021): onReceive: com.google.android.c2dm.intent.REGISTRATION
05-06 11:18:17.519: V/GCMBroadcastReceiver(4021): GCM IntentService class: com.appname.GCMIntentService
05-06 11:18:17.519: V/GCMBaseIntentService(4021): Acquiring wakelock
05-06 11:18:17.539: V/GCMBaseIntentService(4021): Intent service name: GCMIntentService-DynamicSenderIds-4
05-06 11:18:17.539: D/GCMBaseIntentService(4021): handleRegistration: registrationId = APA91bFNWYtZp2DTdK4rMLrIKzvktSp64lFK3__AM-..., error = null, unregistered = null
05-06 11:18:17.539: D/GCMRegistrar(4021): resetting backoff for com.appname
05-06 11:18:17.544: V/GCMRegistrar(4021): Saving regId on app version 3
05-06 11:18:17.549: V/GCMBaseIntentService(4021): Releasing wakelock
05-06 11:18:17.549: D/GCMIntentService(4021): GCMIntentService.onRegistered in GCMIntentService.java:81 :: WLGCMIntentService: Registered at the GCM server with registration id APA91bFNWYtZp2DTdK4rMLrIKzvktSp64lFK3__AM-...
05-06 11:18:17.584: D/NONE(4021): onReadyToSubscribe
05-06 11:18:17.594: W/NONE(4021): Event source callback is already registered with alias: scoring
05-06 11:18:18.234: E/ViewRootImpl(4021): sendUserActionEvent() mView == null
05-06 11:18:18.419: D/NONE(4021): cantidad: 1
05-06 11:18:19.089: D/NONE(4021): Piggybacking event transmission
05-06 11:18:19.099: D/NONE(4021): Flush called
05-06 11:18:48.674: V/GCMBroadcastReceiver(4021): onReceive: com.google.android.c2dm.intent.RECEIVE
05-06 11:18:48.674: V/GCMBroadcastReceiver(4021): GCM IntentService class: com.appname.GCMIntentService
05-06 11:18:48.674: V/GCMBaseIntentService(4021): Acquiring wakelock
05-06 11:18:48.684: V/GCMBaseIntentService(4021): Intent service name: GCMIntentService-DynamicSenderIds-5
05-06 11:18:48.699: V/GCMBaseIntentService(4021): Releasing wakelock
05-06 11:18:48.699: D/GCMIntentService(4021): GCMIntentService.onMessage in GCMIntentService.java:107 :: WLGCMIntentService: Received a message from the GCM server
05-06 11:18:48.709: W/GCMIntentService(4021): GCMIntentService.onMessage in GCMIntentService.java:114 :: Unable to update badge while received push notification, becasue failed to parse badge number null, badge must be an integer number.
05-06 11:18:48.714: D/push(4021): Push$1.onReceive in Push.java:91 :: Push: Queuing message for dispatch to javascript
05-06 11:18:48.719: D/push(4021): Push$1.onReceive in Push.java:97 :: Push: App on foreground and init completed. Add message from intent to pending: Message(alert=nueva notificacion, badge=1, sound=null, priority=0, visibility=1, redact=null, payload={"apellido":" ","tipoDoc":"DNI","alias":"scoring","lsmHasta":"","dictamen":"REINTENTO","prodOfrecer":"","nombre":" ","tipoCarga":"N","nroDoc":"33312","rechazo":"Reintente la consulta.","lsmDesde":"","docAPresentar":"","lc":""}, category=null, bridge=true)
05-06 11:18:48.719: D/push(4021): Push.dispatchPending in Push.java:395 :: Dispatching to javascript Message(alert=nueva notificacion, badge=1, sound=null, priority=0, visibility=1, redact=null, payload={"apellido":" ","tipoDoc":"DNI","alias":"scoring","lsmHasta":"","dictamen":"REINTENTO","prodOfrecer":"","nombre":" ","tipoCarga":"N","nroDoc":"33312","rechazo":"Reintente la consulta.","lsmDesde":"","docAPresentar":"","lc":""}, category=null, bridge=true)
05-06 11:23:18.494: D/CordovaActivity(4021): Paused the application!
05-06 11:23:18.494: D/CordovaWebView(4021): Handle the pause
05-06 11:23:18.499: D/WLClient(4021): WLClient$ActivityListener.onActivityPaused in WLClient.java:1293 :: on activity paused com.appname.appname . activity count = 0
05-06 11:23:18.519: D/NONE(4021): Flush called
05-06 11:23:18.544: D/WLClient(4021): WLClient$ActivityListener.onActivitySaveInstanceState in WLClient.java:1305 :: on activity save instance state com.appname.appname
05-06 11:23:18.549: D/WLClient(4021): WLClient$ActivityListener.onActivityStopped in WLClient.java:1317 :: on activity stopped com.appname.appname
答案 0 :(得分:0)
我在适配器中使用属性
调用了一个方法securityTest="wl_unprotected"
删除了解决我的问题。