GCM - 推送通知需要多长时间才能到达设备? [英] GCM - How long does it take for push notifications to reach the device?

查看:21
本文介绍了GCM - 推送通知需要多长时间才能到达设备?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对接收推送通知消息的速度感兴趣(使用 GCM).发送的推送通知需要多长时间才能到达设备,特别是当我向大量设备(如 100,000 甚至 1,000,000)发送消息时?

I'm interested on the speed of receiving push notification messages (using GCM). How long does it take for sent push notifications to reach the device, specially when i send a message to a large number of devices (like 100,000 or even 1,000,000) ?

推荐答案

GCM 旨在在设备可用时立即发送通知.如 GCM Lifetime of a Message 文档中所述:

GCM was designed to send the notification as soon as the device is available. As stated in the GCM Lifetime of a Message docs:

在最好的情况下,如果设备连接到 GCM,屏幕打开并且没有限制限制,消息将立即传递.

In the best-case scenario, if the device is connected to GCM, the screen is on and there are no throttling restrictions, the message will be delivered right away.

如果您指的是平均速度,则在 Google IO '15 (01:57):

If you are referring to the average speed, it was mentioned back in Google IO '15 (01:57):

..50 毫秒,如果设备在线..

..50milliseconds on average if the devices are online..

还有一些因素会影响通知本身的传递.其中一个示例是设置 delay_while_idle 标志(有关更多信息,请参阅消息文档的 GCM 生命周期).希望这可以清楚地说明您的要求.干杯!:D

There are also some factors which you can affect the delivery of the notification itself. One example of this is setting the delay_while_idle flag (refer to GCM Lifetime of a Message docs for more info). Hope this gives clarity to what you were asking. Cheers! :D

PS:根据最近的 IO '16,他们现在拥有 Firebase 云消息传递,它的核心是基于GCM.小心检查出来.;)

PS: As per the recent IO '16, they now have the Firebase Cloud Messaging, where it's core is based on GCM. Care to check it out. ;)

这篇关于GCM - 推送通知需要多长时间才能到达设备?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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