问题描述
我们正在构建一个消息传递应用程序,并且在消息传递方面遇到了问题.
We are building a messaging app and we are facing issues with messages delivery.
我们当前正在使用socket.io在正在运行的应用程序上发送消息,但是事实证明,它非常不可靠. (问题在于网络速度慢,超时时间过长,应用程序处于打ze模式时出现问题……)
We are currently using socket.io to send messages on a running app but it's been proven highly unreliable. (Problem with slow network, late timeout, problem when app is in Doze mode,...)
我们正在考虑切换到FCM,但是我们对可靠性和速度存在疑问.我们不想更改所有内容,之后再看到它不如想要的那样可靠.
We are thinking about switching to FCM but we have questions regarding reliability and speed. We don't want to change everything to see afterwards that it's not as reliable as wanted.
您是否已经在生产应用程序上对每条消息使用FCM?即使应用正在运行?
Have you already used FCM on a production app for every message ? Even when the app is running ?
推荐答案
很难为此提供具体答案.可靠性方面,我会说FCM很好.
It's hard to provide a concrete answer for this. Reliability wise, I would say FCM is pretty good.
预期的行为是,如果您已成功将有效负载发送到FCM服务器,则它将尽快发送消息.在打ze睡时, 低优先级消息是由FCM存储直到设备退出打ze模式.
Expected behavior is, if you successfully sent your payload to the FCM servers, it will send the message(s) as soon as feasible. When in doze, a low priority message is stored by FCM until the device is out of doze mode.
文档几乎描述了如何在FCM服务器中处理消息以及所有其他相关行为.
The documentation pretty much describes how the messages are handled in the FCM servers and all other related behaviors.
这篇关于Firebase云消息传递可靠性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!