6.1. Data Push Essentials
Data pushing in a web application context implies the server sending data to a browser-based client without the client necessarily requesting it. There are ways to achieve this partially and fully, but before we explore those, let's gain an understanding of where data pushing is important. Understanding the usage scenarios will help you choose the correct alternative and highlight the potential upsides and downsides of these alternatives.
6.1.1. Data Push Usage Scenarios
The financial market data continuously changes as buyers and sellers present their bid and offer prices and engage in trading. If you are building an investment management application or simply an application for displaying market data, then you want to receive the latest data snapshot as soon as it's available. In such cases, server-initiated data updates are suitable.
Online collaboration and chat applications benefit from real-time instant updates. Message passing between the interacting clients is appropriate in this case. Monitoring applications could be more effective if the object being monitored sent a status message to the monitor at periodic intervals to report its current state. Online gaming applications need to instantly relay a player's choices to all other participants for the game to be consistent and relevant.
In all these cases and more data pushing provides the basis for the application's usability and pertinence. Next, you'll see the ways to push data.
6.1.2. The ...
Get Professional BlazeDS: Creating Rich Internet Applications with Flex® and Java® 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.