gpt4 book ai didi

android - GCM Missmatched 信使错误

转载 作者:行者123 更新时间:2023-11-30 02:02:00 25 4
gpt4 key购买 nike

当我打电话

instanceID.getToken(default_senderId, scope, null)

这个函数我看到了IOException

Missmatched messenger
not posting request to register [package name] because of backoff period
java.io.IOException: SERVICE_NOT_AVAILABLE

AndroidManifest.xml

    <receiver
android:name="com.google.android.gms.gcm.GcmReceiver"
android:exported="true"
android:permission="com.google.android.c2dm.permission.SEND">
<intent-filter>
<action android:name="com.google.android.c2dm.intent.RECEIVE" />
<action android:name="com.google.android.c2dm.intent.REGISTRATION" />
<category android:name="[package name]" />
</intent-filter>
</receiver>


<service
android:name=".gcm.RegistrationIntentService"
android:exported="false"></service>

这是最显着的部分

如何解决这个问题?

最佳答案

这里的“Missmatched messenger”没有关系,重要的部分是:

not posting request to register [package name] because of backoff period

当 getToken 请求因指数退避而被阻止以保护 InstanceId 服务器时,将记录此信息。本质上,如果对服务器的请求失败,则会设置一个短暂的退避时间(秒级),其他请求将被阻止。如果在初始退避请求之后仍然失败,它将呈指数增长。

这是为了保护 Iid 服务器免受客户端行为不当的影响,并帮助避免任何中断情况变得更糟。

关于android - GCM Missmatched 信使错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31306637/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com