14. Push Messages
Push messaging is a communication method in which a connected client is informed of an event in a remote system by receiving notifications from that system. As opposed to pull messages, where the client needs to query the remote system at given time intervals, pushed messages are triggered by the remote system itself without having the client ask for a status update. Android supports message push through the Google Cloud Messaging (GCM) library. GCM is available on all Android devices running API Level 8 or higher, which should include most active devices. This chapter shows how to integrate with GCM and how to send and receive messages.
Google Cloud Messaging Setup
Google Cloud Messaging relies on the presence of both the ...
Get The Android™ Developer’s Cookbook: Building Applications with the Android SDK, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.