Reputation: 8145
I'm new with Android GCM and I downloaded the appengine demo application provided by Google. I was looking at the server side and first I thought that the servlets (HomeServlet, RegisterServlet, etc.) were part of GCM, but when I looked into client side I saw that first it's called GCMRegistrar.register and, if it's successfull, then a post request is sent to the register servlet on the server side.
So I guess that these servlets should be replaced with my server application (it's currently running without GCM) and I only need to call GCMRegistrar.register in my client side for the device to be registered. Am I right?
Upvotes: 0
Views: 431
Reputation: 656
Here is also a simple tutorial with step by step implementation
http://androidv5.wordpress.com/2012/08/15/how-to-implement-google-cloud-messaging/
Upvotes: 0
Reputation: 9527
Here is a step by step overview of implementing GCM. It includes registration on the device, then sending to your server for storage (the registration id), and finally sending notifications to GCM from your server.
http://fryerblog.com/post/30057483199/implementing-push-notifications-with-gcm
Upvotes: 1
Reputation: 1006539
So I guess that these servlets should be replaced with my server application (it's currently running without GCM)
Correct.
and I only need to call GCMRegistrar.register in my client side for the device to be registered.
Also correct.
Upvotes: 1