Mobile Messaging

Consider the following scenario. Athul is riding the subway and is viewing stock quotes on his PDA. He suddenly realizes that he wants to buy 100 shares of eComm Ware Corporation. He taps his stylus on the item in his portfolio, and enters the quantity and the highest price he wants to pay. He then taps on the ‘Buy’ button and feels confident that his transaction will be executed exactly once, without any errors. How confident can Athul feel that his transaction will succeed when he knows that there's no reliable network coverage?

In this section we'll see how messaging or information transactions can be carried out with high reliability in spite of the disconnected operation of mobile equipment. We will also see how to deal with the delivery of real-time information to mobile devices. The next generation of message-oriented middleware (MOM) is best suited to support these kinds of applications. We will describe how such applications are implemented using JMS.

Challenges Faced by Mobile Applications

Traditional computing environments are used to having remote access to web pages (HTTP), remote access to files (FTP, NFS), and mail servers (POP3, IMAP, SMTP). These networking requirements are rather rudimentary where communications between devices are limited to a specific application like e-mail or web browsing.

However, multiple devices of a single consumer interacting in a logical way, present a significant challenge to developers of mobile applications (applications that run on a PDA-like mobile device). In these days of volatile market conditions, and world traveling consumers, distributed information systems allow prices to adjust faster to changes in the market place. Decision-making would be a lot easier if people had access to real-time information on mobile devices. When a company's bottom-line totally depends on ‘information at your finger-tips', mobile applications have to satisfy some demanding requirements. Sending off a stock purchase request and hoping, wishing, and praying that the transaction succeeded is not an option, so mobile business applications must be reliable, secure, scaleable, robust, and flexible:

  • Reliability means that a mobile application can reliably transfer messages from one end to the other taking into account unreliable communications and adopting error-recovery mechanisms.

  • Security means authentication of users; confidentiality; non-repudiation of transactions, etc.

  • Scalability means that a mobile application may integrate thousands or even millions of users.

  • Robustness implies that a transaction issued on a mobile device needs to be executed exactly once, in spite of poor network coverage or failures.

  • Finally, mobile applications ought to be flexible in order to accommodate different bearers (transmission technologies: Short Message Service, Groupe Special Mobile, General Packet Radio Service, Universal Mobile Telecommunications System, Bluetooth, Infrared) and interaction styles (synchronous, asynchronous, transactional, one-to-one, or many-to-many).

MOM and Wireless Connectivity

MOMs ensure loose coupling of software components and therefore allow greater flexibility when developing mobile applications. This is because applications communicate with one another indirectly by passing messages through a message service. MOMs will prove even more valuable for developing sophisticated mobile applications because:

  • MOMs support disconnected operation: application A can send a message to application B, even when B is not available (because it's not running or lacks any network coverage).

  • MOMs guarantee the delivery of messages: at the middleware level messages are held in databases and forwarded to their recipients as soon as they become available.

  • MOM libraries can be very lightweight.

  • MOMs support both transactional interactions and real-time delivery of volatile information.

  • The MOM model is intuitive and easy to learn. This means that distributed applications can be developed and deployed more quickly.

The Wireless JMS

The JMS messaging server is the sort of "Home Base" of the devices running the JMS client library. It performs activities such as message queuing and forwarding, access control to queues and topics, message encryption, transaction management, and protocol translation. The queue on the server may store a large quantity of messages, and may be able to process hundreds or thousands of messages per second, depending mainly on message size and the speed of the computer hosting it. It may be implemented using a transactional database.

In order to achieve the smallest possible client footprint, the messaging server relieves the client library of most of the work of maintaining JMS state information about open topics and queues, subscriptions, message filters, etc. With this approach, it is possible to reduce the footprint of the applications running on the mobile device aggressively, while maintaining the JMS semantics:

click to expand

The JMS messaging server should be able to translate and mediate between transport protocols and bearers. This is necessary when, for example, an application running on a Windows NT PC sends a JMS message containing the current stock quote to both a PalmOS device and an EPOC device that have subscribed to the same Publish/Subscribe topic. The PC may transmit the message to the messaging server using TCP/IP over Ethernet, informing the server that the message is to be transmitted to the topic "NASDAQ Stock Quote". The server looks up the subscribers for the topic "NASDAQ Stock Quote", and determines that the PalmOS device is to be contacted using SMS (Short Message Service), while the EPOC device can be reached through Bluetooth. The producer application does not need to know about those bearers, because the message server performs the protocol translation from TCP to SMS and Bluetooth transparently. An application running on an SMS bearer can be changed to use a GPRS (General Packet Radio Service) bearer without modification of the application, because JMS abstracts the bearer.



Professional JMS
Professional JMS
ISBN: 1861004931
EAN: 2147483647
Year: 2000
Pages: 154

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net