FCM behavior when offline for iOS

匆匆过客 提交于 2019-12-03 08:46:13

The time_to_live is AFAIK applicable to both Android and iOS. However, since the process of sending the message to iOS devices for FCM goes like this:

App Server > FCM Server > APNs > iOS device

It is safe to say that only the FCM Server makes use of the time_to_live, as per it's description:

This parameter specifies how long (in seconds) the message should be kept in FCM storage if the device is offline. The maximum time to live supported is 4 weeks, and the default value is 4 weeks. For more information, see Setting the lifespan of a message.

Looking around, the behavior for APNs when sending to offline devices is (from the Apple docs):

Apple Push Notification service includes a Quality of Service (QoS) component that performs a store-and-forward function. If APNs attempts to deliver a notification and the destination device is offline, APNs stores the notification for a limited period of time and delivers it when the device becomes available again. This component stores only the most recent notification per device and per app. If a device is offline, sending a notification request targeting that device causes the previous request to be discarded. If a device remains offline for a long time, all its stored notifications in APNs are discarded.

As of now, delay_while_idle is now deprecated.

The way I know that you could do to wake up an iOS phone (online/connected to a decent network) is to simply set the priority to high.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!