Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Push notifications on Android: Google GCM vs. Amazon SNS?

My Android app needs simple push notifications to be informed about the appearance of new data on a server. Android provides Google Cloud Messaging (GCM) which would seem to fit.

However, devices running lower than Android 4.0.4 require a Google account to be present on the phone (per Google platform stats as of 10/1/2012, this is currently about 75% of Android phones). And it does not seem to be a good experience to be asking users to set up a Google account in the middle of an unrelated application activity.

Are there any suggestions for a more universal push mechanism that can be used on the Android platform? For example, what are the pros & cons of Amazon SNS? Any other candidates?

like image 304
gcl1 Avatar asked Oct 05 '12 20:10

gcl1


2 Answers

This service also provide a generic interface to Android and iOS, and is much cheaper than parse: PushApps

A new wiki site is now available for PushApps - PushApps wiki

like image 132
Asaf Avatar answered Oct 12 '22 23:10

Asaf


I highly suggest the Parse API. You can find it here: http://parse.com. Not only is it universal for Android devices, but is also cross platform for iOS, JavaScript, and REST as well. You can do simple text push messages, or complex ones that send a JSON string to the pushed device. I'm not exactly sure the scope you need for your app (you may need more server-side control, although Parse is now providing a way to run code in the cloud as well), but definitely check out Parse.

EDIT:

First, Parse was really just a wrapper around GCM, so it wasn't truly an answer to your question because it is, at the bottom line, GCM with some provided services to get you up and running with a push server more quickly.

Second, Parse has been announced as shutting down, and will not be supported after January 28, 2017: Parse blog announcement

Third, to truly answer your question, there are indeed some alternatives to GCM and SNS that can provide what you need. Without going into detail or pros/cons for each approach, here are a few alternatives to get you researching:

  • Web sockets
  • HTTP long-polling
  • Depending on your use case, periodical polling from the server (i.e. poll once a day to get a "feed" for the latest notifications.
  • Some type of MQTT protocol implementation
like image 24
dennisdrew Avatar answered Oct 13 '22 00:10

dennisdrew