我正在开发一个需要从 Php 服务器向 Android 设备发送批量推送通知的应用程序。有什么方法可以在不使用任何循环的情况下从 Php 服务器向所有设备发送多个推送通知。 *因为这个循环过程减少了服务器对客户端的响应时间。
最佳答案
Is there any way to send multiple push notification from Php server to all devices without using any Loop
You can send a message to up to 1000 devices at a time .如果您需要发送更多,则需要一个循环。
because this loop process reduce response time to client from the server.
与从您的服务器到 GCM 服务器的通信所需的网络时间、消息存储在 GCM 服务器上的时间、从服务器到设备等。循环所需的微秒将被其余过程所需的秒数淹没。
关于php - 从 php 服务器向 android 设备发送批量推送通知,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27041220/