Firebase匿名用户会发生什么情况? [英] What happens to Firebase anonymous users?

查看:141
本文介绍了Firebase匿名用户会发生什么情况?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



Firebase文档真的很糟糕,而且没有用户名和密码,解释一切,并期望开发人员找出自己。
我在旧版本的文档中发现匿名会话会根据Login& Auth选项卡,但即使没有提到这意味着只是会话结束,或者这意味着用户ID也将从我的应用程序用户列表中删除,或者是什么发生了什么?



我发现这个答案,但它确实是不能接受的。匿名用户的数量将会增长很快,如果你做一个网络应用程序,并使每一件事情都很难。
我甚至无法在仪表板中看到我的应用程序用户数量!
那么,我该怎么办?我应该自己为我的数据开发一个仪表板吗?还是Firebase团队应该这样做?至少对于管理用户,我应该有更多的权力,而不仅仅是搜索用户与他们的电子邮件,当你使用自定义登录,你也不能这样做也是这样。

如果你想要匿名用户从你的用户列表中删除,你必须写一个服务来为你做。



由于firebase没有提供列出注册用户的方法,您必须确保您在数据库中存储某种用户列表。然后,您可以使用node.js admin sdk来 get用户数据,请检查用户是匿名,并在用户创建时找到 。出于性能方面的原因,您可能希望将这些信息存储在数据库的特殊区域,并一次性检索。一旦确定了一个陈旧的匿名用户,他们可以轻松删除


I want to know what will happen to the users of my app that I used anonymous sign in method for them.

The Firebase documentation is really BAD and didn't explain everything and expect developer to find out himself. I found in its old version documentation that anonymous session will expires based on the expiration time has been set in Login & Auth tab, but even there didn't mention this means just the session ends or it means that user id will remove also from my app users list or what EXACTLY happened?

I found this answer but it really is not acceptable. The number of anonymous users will grow very very fast if you do a web app and make every thing hard. I even cannot see the number of my app users in my dashboard!!!!! So, what should i do? should i develop a dashboard for my data myself or Firebase team should do it? At least for managing users i should have more power than just searching user with their email and when you use custom login you cannot do this also.

解决方案

If you'd like anonymous users to be removed from your user list, you'll have to write a service to do that for you.

Since firebase doesn't provide a way to list registered users, you'll have to make sure you're storing some sort of user list in the database. You can then use the node.js admin sdk to get user data, check if the user is anonymous, and find when the user was created. For performance reasons, you may wish to store this information in a special area of your database and retrieve it all at once. Once you've identified a stale anonymous user they can be easily deleted.

这篇关于Firebase匿名用户会发生什么情况?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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