I know that exists similar questions on site, but I confused because http
and xmpp
have difference limit:
this page say differences between http
and xmpp
.
first limit is [xmpp
& http
]: up to 4KB of data
second limit is:
http
: You can send out a message to 1000 users at a time. (ref)
xmpp
: For each sender ID, GCM allows 1000 connections in parallel. (ref)
You can send out a message to 1000 users at a time. so if you have more users you'll have to send the message multiple times from your server but to different users each time (ref)
third limit is:
http
: I couldn't found this limit in android developer:
There is a limit on how many messages can be stored without collapsing. That limit is currently 100. If the limit is reached, all stored messages are discarded. Then when the device is back online, it receives a special message indicating that the limit was reached. The application can then handle the situation properly, typically by requesting a full sync. (ref)
xmpp
:
Every message sent to CCS receives either an ACK or a NACK response. Messages that haven't received one of these responses are considered pending. If the pending message count reaches 100, the app server should stop sending new messages and wait for CCS to acknowledge some of the existing pending messages (ref)
my questions:
1.in second limit, if we use http method and have 2000 users, should we send message twice, every time to 1000 users?, can we do it?
2.xmpp
can not support multicast messaging, can we use topic for multicast in xmpp
?
- any limit on broadcast messaging by topics? (except ref)
4.in third limit, if i send a message to 300 users, and One hundred top users be offline, do they recieve message
or any notification
when come back and online? (note: use broadcast for http
and loop for xmpp
)
do this limit effect in topic way ?
do exists any difference in third limit between
http
andxmpp
?
7.exists other limit in http
or xmpp
?
Yes you can do that. While using
HTTP
you may have a batch size of 1000(recipients).Yes.
Topic
messages isPubSub
method and if your clients registered to a given topic, you can sent a push notification to all of them with just one request.No limitation. Once there was a 1 million subscriber limit per app on
Topic Messaging
, which doesn't exist anymore.You confused the third limit:
HTTP
) is about a single client, not all of them. So if you send more than 100 messages to a single client while he is offline, when he gets back online again, none of them will be deliver.XMPP
) is about all of the queue and it happens in the server side. It means you have to send no messages to GCM if there exists more than 100 unACKed messages there.So you have no problem considering offline users, GCM will handle to deliver message to all of them, when they come back online.
No.
I explained it in 4.
I don't remember any more.