Firebase存储和数据库规则通信 [英] firebase storage and database rules communication

查看:154
本文介绍了Firebase存储和数据库规则通信的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要将某些变量存储在数据库和存储中。但重要的是要确保将这些变量保存在两个数据库中,而不仅仅保存在一个数据库中,而且这些变量必须具有相同的值。但是我看到存储和数据库没有通信。
如何解决这个问题?解决方案简单的答案是,目前,来自一个服务的安全规则不能从另一个服务访问数据。请参阅这个线程的更多信息(类似的一般问题)。

如果你希望分享的数据是用户特定的,你可以创建自定义标记,其中包含这个数据,可以跨服务共享(因为这两个服务得到同样的道理)。

i need to store certain variables in the database and in the storage. but is important to have the certainty that this variables will be saved in the two databases and not only in one, furthermore this variables must be have the same values. but i see that storage and database not are in communication. how do I fix this?

解决方案

The short answer is that currently, security rules from one service can't access data from another service. See this thread for more info (similar general problem).

If the data you're hoping to share is user specific, you can mint custom tokens which contain this data, that can be shared across services (as both services get the same token).

这篇关于Firebase存储和数据库规则通信的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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