Introduction to GCM
In this post, I will be discussing about Introduction to Google Cloud Messaging service. You should have heard the word ‘GCM’ somewhere and you are here to understand what it is and how it is used in Android applications.
Following this post, I will be creating couple of Android applications incorporating GCM service to demonstrate in what are the different ways we can use GCM, so I request you to keep track of GCM tutorial series gonna be published here.
One best way to track the tutorials I post here is, do subsribe.
Let us get started with ‘Introduction to GCM’.
What is GCM?
GCM – Google Cloud Messaging is a free service from Google to send and receive messages to and from Android devices.
This video will give you quick introduction of GCM, watch it and do let us know what you think right from here.
Primary characteristics of Google Cloud Messaging (GCM)
- It allows third party application servers (Java, Dot Net or even Php server) to send messages to their Android applications.
- Using the GCM Cloud Connection Server, you can receive upstream messages from the user’s device.
- An Android application on an Android device doesn’t need to be running to receive messages. The system will wake up the Android application via Intent broadcast when the message arrives, as long as the application is set up with the proper broadcast receiver and permissions.
- It does not provide any built-in user interface or other handling for message data. GCM simply passes raw message data received straight to the Android application. Handling data is upto the developer.
For example, the application might post a notification, display a custom user interface, or silently sync data.
- It requires devices running Android 2.2 or higher that also have the Google Play Store application installed, or or an emulator running Android 2.2 with Google APIs.
- It uses an existing connection for Google services. For pre-3.0 devices, this requires users to set up their Google account on their mobile devices. A Google account is not a requirement on devices running Android 4.0.4 or higher.
I have written sample applications based on GCM, please find them below:
- Simple Push Notification Application – Send message from Server to device in which App is installed
- Multicast Push Notification Application (Greeting Application) – Send Greeting messages to one or more Users using GCM Multicast feature
- This space will be updated when there is new Application created using GCM, so keep watching !
It’s time to start creating GCM feature enabled Android application, choose the application which you wanna create from the above links.
Do let us know your comments and feedback from commentbox.