我在开发谷歌云推送的过程中遇到了一些问题,想请问一下有没有什么解决办法。
MainActivty开启了RegistrationService调用
InstanceID instanceID = InstanceID.getInstance(this);
String token = instanceID.getToken(getString(R.string.gcm_defaultSenderId),
GoogleCloudMessaging.INSTANCE_ID_SCOPE, null);
去申请registration id,但log却打出了超时,如下:
09-20 20:08:06.135: I/Adreno-EGL(31641): <qeglDrvAPI_eglInitialize:410>: EGL 1.4 QUALCOMM build: ()
09-20 20:08:06.135: I/Adreno-EGL(31641): OpenGL ES Shader Compiler Version: E031.24.00.08+13 09-20 20:08:06.135: I/Adreno-EGL(31641): Build Date: 03/28/14 Fr 09-20 20:08:06.135: I/Adreno-EGL(31641): Local Branch: 0328_AU200_patches
09-20 20:08:06.135: I/Adreno-EGL(31641): Remote Branch:
09-20 20:08:06.135: I/Adreno-EGL(31641): Local Patches:
09-20 20:08:06.135: I/Adreno-EGL(31641): Reconstruct Branch:
09-20 20:08:06.165: D/OpenGLRenderer(31641): Enabling debug mode 0
09-20 20:08:06.175: D/ProgressBar(31641): updateDrawableBounds: left = 0
09-20 20:08:06.175: D/ProgressBar(31641): updateDrawableBounds: top = 0
09-20 20:08:06.175: D/ProgressBar(31641): updateDrawableBounds: right = 144
09-20 20:08:06.175: D/ProgressBar(31641): updateDrawableBounds: bottom = 144
09-20 20:08:06.205: W/InstanceID/Rpc(31641): Found 10211
09-20 20:08:06.235: I/dalvikvm(31641): Total arena pages for JIT: 11
09-20 20:08:06.235: I/dalvikvm(31641): Total arena pages for JIT: 12
09-20 20:08:06.235: I/dalvikvm(31641): Total arena pages for JIT: 13
09-20 20:08:06.235: I/dalvikvm(31641): Total arena pages for JIT: 14
09-20 20:08:06.275: D/dalvikvm(31641): DexOpt: couldn't find field Landroid/os/Message;.sendingUid
09-20 20:08:06.275: W/dalvikvm(31641): VFY: unable to resolve instance field 131
09-20 20:08:06.275: D/dalvikvm(31641): VFY: replacing opcode 0x52 at 0x0000
09-20 20:08:36.305: W/InstanceID/Rpc(31641): No response android.os.ConditionVariable@42e92cf8
09-20 20:08:36.305: D/RegIntentService(31641): Failed to complete token refresh
09-20 20:08:36.305: D/RegIntentService(31641): java.io.IOException: TIMEOUT
09-20 20:08:36.305: D/RegIntentService(31641): at com.google.android.gms.iid.zzc.zzb(Unknown Source)
09-20 20:08:36.305: D/RegIntentService(31641): at com.google.android.gms.iid.zzc.zza(Unknown Source)
09-20 20:08:36.305: D/RegIntentService(31641): at com.google.android.gms.iid.InstanceID.zzc(Unknown Source)
09-20 20:08:36.305: D/RegIntentService(31641): at com.google.android.gms.iid.InstanceID.getToken(Unknown Source)
09-20 20:08:36.305: D/RegIntentService(31641): at com.example.atest.RegistrationIntentService.onHandleIntent(RegistrationIntentService.java:53)
09-20 20:08:36.305: D/RegIntentService(31641): at android.app.IntentService$ServiceHandler.handleMessage(IntentService.java:65)
09-20 20:08:36.305: D/RegIntentService(31641): at android.os.Handler.dispatchMessage(Handler.java:102)
09-20 20:08:36.305: D/RegIntentService(31641): at android.os.Looper.loop(Looper.java:146)
09-20 20:08:36.305: D/RegIntentService(31641): at android.os.HandlerThread.run(HandlerThread.java:61)
09-20 20:08:36.355: D/ProgressBar(31641): updateDrawableBounds: left = 0
09-20 20:08:36.355: D/ProgressBar(31641): updateDrawableBounds: top = 72
09-20 20:08:36.355: D/ProgressBar(31641): updateDrawableBounds: right = 0
09-20 20:08:36.355: D/ProgressBar(31641): updateDrawableBounds: bottom = 72
手机还弹出了com.google.process.gapps已停止。
我调试用的手机是国内买的三星s5,G9008W,Android版本是4.4.2,刷的是4.4.3的GAPPS,Google Play服务的版本是8.1.15。我已经尝试过用三个VPN了,服务器在美国,手机也能打开google play store和Youtube。
有没有人知道是什么导致了这个问题,谢谢。