Firebase Android - 跳过初始化 [英] Firebase Android - Skipping initialization

查看:555
本文介绍了Firebase Android - 跳过初始化的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前正在实施一个使用Firebase云消息传递的Android应用程序。
我已经根据Firebase页面上的教程实现了所有的功能。

然而,每当我尝试运行我的应用程序时,Firebase初始化失败。在模拟器和实际设备上,我都得到了这个调试信息:

  D / FirebaseApp:com.google.firebase。 auth.FirebaseAuth没有链接。跳过初始化。 
W / InstanceID / Rpc:找到10010
D / FirebaseApp:com.google.firebase.crash.FirebaseCrash未关联。跳过初始化。

它不会调用 InstanceIDListener
奇怪的是,这个模拟器曾经工作过一次。 / p>

< service android:name =。MyFirebaseInstanceIDService>
< intent-filter>
< action android:name =com.google.firebase.INSTANCE_ID_EVENT/>
< / intent-filter>
< / service>


I am currently implementing an Android app, which uses Firebase Cloud Messaging. I've implemented everything according to the tutorial on the Firebase page.

However, whenever I try to run my app it seems like the Firebase initialization fails. Both, on an emulator and on a real device I get this debug message:

D/FirebaseApp: com.google.firebase.auth.FirebaseAuth is not linked. Skipping initialization.
W/InstanceID/Rpc: Found 10010
D/FirebaseApp: com.google.firebase.crash.FirebaseCrash is not linked. Skipping initialization.

It doesn't call the InstanceIDListener. And it strangely worked with the emulator once.

解决方案

You have to add the following to your android manifest:

<service android:name=".MyFirebaseInstanceIDService">
    <intent-filter>
        <action android:name="com.google.firebase.INSTANCE_ID_EVENT"/>
    </intent-filter>
</service>

这篇关于Firebase Android - 跳过初始化的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆