Programmers now can get servers to send alerts to Google’s browser rather than requiring the browser itself to constantly check for them.
The mechanics of push notifications work in Chrome.
In a step to help browser-based apps catch up with the abilities of other software, Google has made it possible for programmers to push notifications to Web apps running in Chrome.
On Thursday, Google enabled a service called Google Cloud Messaging for Chrome (GCM) that brings push notifications to its browser and to Chrome OS, its browser-based operating system. Mark Scott, a Google product manager, announced the service in a blog post.
The technology means that servers can send a message — a stock price alert or news item, for example — that triggers an action in the browser. To use the service, developers’ own servers send a message to Google’s GCM server, which then communicates with Chrome, which then communicates with the developers’ Chrome extension or Chrome app, which takes the appropriate action like popping up a notification or opening a particular Web page.
“Your message is…delivered in near real time to Chrome,” Scott said. Users must be logged into Chrome for the service to work.
It may sound like a roundabout communication approach, but it means that Web apps need not constantly poll servers to see if an alert is ready. That wastes network usage and battery power, Google argues.
Google announced the move the week before Google I/O, the company’s developer-oriented conference that has a major emphasis on writing browser and Android apps and on using Google’s wide range of application programming interfaces (APIs).
The service is a close parallel to Google Cloud Messaging for Android, Scott said.
Push messaging, a staple of the mobile-phone world, can help Web developers keep up with what others can do. But as with all notification systems, it contributes to the potential problem: overwhelming users as apps, services, and people constantly vie for attention.
Via CNet