| Android Push Notification Service (C2DM) Delivery Channel |
The C2DM Delivery Channel enables Connect to deliver messages to applications deployed on Android devices. Since each Android application requires dedicated connections to the APNS servers, each application must be configured as a separate Delivery Channel.
The Delivery Channel software component resides in the import/channel_android.jar file that is included with the Connect software distribution. The configuration information for each delivery channel must be manually stored in the channel_android.jar file before being deployed to the cluster nodes.
In Connect, each Android Delivery Channel instance has a name, such as “android-pushtest”, and a properties file that is named based on the channel name. For example, if the Delivery Channel instance is named “android-pushtest”, then the channel_apns.jar file should contains a properties file named “android-pushtest.properties”. The properties file should contain the properties defined in the table below:
| Property Name | Value |
|---|---|
| android.sender.email | The email address (Sender ID) of the application developer. This address should have been registered as a C2DM Sender ID with Google. |
| android.sender.password | The account password for the Sender ID (android.sender.email).
Note: Encrypted passwords are not currently supported in Android Delivery Channel.
|
| android.sender.application | Name of application. Used when fetching a ClientLogin Auth token from Google. |
| android.payload.subject | The Android delivery channel sends two key-value pairs in the C2DM message payload: the subject data and the content data. This property specifies the key of the subject data; if the value of this property is "sub123", the Android delivery channel will include the key "data.sub123" with the message subject line as the value. |
| android.payload.content | The Android delivery channel sends two key-value pairs in the C2DM message payload: the subject data and the content data. This property specifies the key of the content data; if the value of this property is "cont123", the Android delivery channel will include the key "data.cont123" with the message content as the value. |
[email protected] android.sender.password=Password.2012 android.sender.application=PushEndpointDemo android.payload.subject=payload1 android.payload.content=payload2
zip channel_android.jar android-pushtest.properties
This operation should be performed using the channel_android.jar file in the Connect
installation directory.