Search code examples
androidpushandroid-c2dm

c2dm push to many devices


I planning the application pushes a newsletter to all registered users.

Number of users is approximately 200,000 ~ 300,000.

I'm caring about the traffic issue with google c2dm server.

Can I request to c2dm server in a loop with large number of users using HttpURLConnection?

Will I banned?

I heard something about in this case I must use http 1.1 protocol with keepAlive set true.


Solution

  • C2DM does have quotas, both on the messages per device and total number of messages. you can find the details here: http://code.google.com/android/c2dm/quotas.html

    as it says, 200k is the default limit but you can request a larger quota. i've done this at a company and it was no problem, but i can't say for sure how helpful they will be to the average developer.

    as far as i know, there's no quota on the rate that you send them. you can send them as fast as the google servers will accept your requests.

    I planning the application pushes a newsletter to all registered users.

    you should make sure you aren't trying to push a payload through C2DM. that's clearly a misuse of the service. C2DM must be used to wake up the device only. in your case, the message itself should be "hey device there's a new newsletter on the server, go get it". assuming that's happening but a few times a day at most, it will be within the accepted use for C2DM.