diff --git a/docs/html/google/gcm/adv.jd b/docs/html/google/gcm/adv.jd
index 567b12cbb60c1..245467f51f185 100644
--- a/docs/html/google/gcm/adv.jd
+++ b/docs/html/google/gcm/adv.jd
@@ -96,7 +96,7 @@ invalidate the registration ID. Future attempts to send a message to that device
will get a NotRegistered error. See
How Unregistration Works for more information.
Although is not possible to track the status of each individual message, the -Google APIs Console stats are broken down by messages sent to device, messages +Google Cloud Console stats are broken down by messages sent to device, messages collapsed, and messages waiting for delivery.
GCM will store up to 100 non-collapsible messages. After that, all messages
are discarded from GCM, and a new message is created that tells the client how
far behind it is. The message is delivered through a regular
-com.google.android.c2dm.intent.RECEIVE intent, with the following
-extras:
message_type—The value is always the string
-"deleted_messages".total_deleted—The value is a string with the number of
-deleted messages.com.google.android.c2dm.intent.RECEIVE intent with the
+extra message_type, for which the value is always the string
+"deleted_messages".
+
The application should respond by syncing with the server to recover the discarded messages.
diff --git a/docs/html/google/gcm/client.jd b/docs/html/google/gcm/client.jd index df357a2703090..ee764ef2df871 100644 --- a/docs/html/google/gcm/client.jd +++ b/docs/html/google/gcm/client.jd @@ -416,15 +416,18 @@ private void registerInBackground() { } }.execute(null, null, null); ... - /** - * Sends the registration ID to your server over HTTP, so it can use GCM/HTTP - * or CCS to send messages to your app. Not needed for this demo since the - * device sends upstream messages to a server that echoes back the message - * using the 'from' address in the message. - */ - private void sendRegistrationIdToBackend() { - // Your implementation here. - } +} + +Once you've received your registration ID, send it to your server:
+
+/**
+ * Sends the registration ID to your server over HTTP, so it can use GCM/HTTP
+ * or CCS to send messages to your app. Not needed for this demo since the
+ * device sends upstream messages to a server that echoes back the message
+ * using the 'from' address in the message.
+ */
+private void sendRegistrationIdToBackend() {
+ // Your implementation here.
}
After registering, the app calls {@code storeRegistrationId()} to store the @@ -660,4 +663,3 @@ want to view GCM stats.
Note: Stats on the Google API Console are not enabled for GCM. You must use the Developer Console.
- diff --git a/docs/html/google/gcm/gcm.jd b/docs/html/google/gcm/gcm.jd index 3c80b5f9ae5f1..88bf6591f34eb 100644 --- a/docs/html/google/gcm/gcm.jd +++ b/docs/html/google/gcm/gcm.jd @@ -104,7 +104,7 @@ application server and sending them to the device.To create a Google API project:

Note: If you already have existing projects, -the first page you see will be the Dashboard page. From there -you can create a new project by opening the project drop-down menu (upper left corner) -and choosing Other projects > Create.
https://code.google.com/apis/console/#project:4815162342+
#project: (4815162342 in this
-example). This is your project number, and it will be used later on as the GCM sender ID.Once the project has been created, a page appears that displays your project ID and +project number. For example, Project Number: 670330094152.
+ +To enable the GCM service:
To obtain an API key:
+
-
-
-
-
-
-
- Take note of the API key value (YourKeyWillBeShownHere)
-in this example, as it will be used later on.
Note: If you need to rotate the key, click -Generate new key. A new key will be created while the old one -will still be active for up to 24 hours. If you want to get rid of the old key -immediately (for example, if you feel it was compromised), click Delete key.
+the "recycle key" icon. A new key will be created. If you think the key has been compromised +and you want to delete it immediately, you can accomplish this by deleting the app from +the console. Then create a new entry for the app with the same SHA1 and package name. +Required. When your app server sends a message in GCM, it must specify a target.
For HTTP you must specify the target as one of:
registration_ids: For sending to 1 more more devices (up to 1000).
+registration_ids: For sending to 1 or more devices (up to 1000).
When you send a message to multiple registration IDs, that is called a multicast message.notification_key: For sending to multiple devices owned by a single user.