YOUR FEEDBACK
sahil wrote: How to use onmouseover on marker with c# code, by default when u click on marker...
AJAXWorld RIA Conference
October 20-22 San Jose, CA
Register Today and SAVE !..

2008 East
DIAMOND SPONSOR:
Data Direct
Frontiers in Data Access: The Coming Wave in Data Services
PLATINUM SPONSORS:
Red Hat
The Opening of Virtualization
Intel
Virtualization – Path to Predictive Enterprise
Green Hills
IT Security in a Hostile World
JBoss / freedom oss
Practical SOA Approach
GOLD SPONSORS:
Software AG
The Art & Science of SOA: How Governance Enables Adoption
PlateSpin
Effective Planning for Virtual Infrastructure Growth
Fujitsu
Automated Business Process Discovery & Virtualization Service
Ceedo
Workspace Virtualization
Click For 2007 West
Event Webcasts

2008 East
PLATINUM SPONSORS:
Appcelerator
Think Fast: Accelerate AJAX Development with Appcelerator
GOLD SPONSORS:
DreamFace Interactive
The Ultimate Framework for Creating Personalized Web 2.0 Mashups
ICEsoft
AJAX and Social Computing for the Enterprise
Kaazing
Enterprise Comet: Real–Time, Real–Time, or Real–Time Web 2.0?
Nexaweb
Now Playing: Desktop Apps in the Browser!
Sun
jMaki as an AJAX Mashup Framework
POWER PANELS:
The Business Value
of RIAs
What Lies Beyond AJAX?
KEYNOTES:
Douglas Crockford
Can We Fix the Web?
Anthony Franco
2008: The Year of the RIA
Click For 2007 Event Webcasts

SYS-CON.TV
TOP THREE LINKS YOU MUST CLICK ON


Bringing Real-Time AJAX Development to Java Developers
Betting on Java for AJAX

JMS Destinations can be either looked up by well-known persistent names, or created with a temporary scope. For instance, a site can create a series of poker tables that a user can choose to watch, each with unique names such as "HighStakes" or "Novice." Accordingly, "HighStakes" and "Novice" would be the public names of the JMS topic to which any client would attach. Then, any messages sent to the corresponding "HighStakes" or "Novice" JMS topics on the server would be immediately pushed to only those clients who were interested in them.

Private messages are also supported by such a mapping. In JMS, there is the concept of a temporary Destination, which is scoped to the duration of a communication session. This provides a convenient way for clients and servers to attach and detach short-term channels as necessary. If, for example, there existed a well-known public JMS Queue named "HighStakesSeatRequests" where observers could send messages to attempt to sit and play at the HighStakes table, the corresponding client JMS code might look something like this:

    ObjectMessage seatRequestMessage = myPokerSession.createObjectMessage();
    // ...
    // Fill in pertinent seat reqeuest information on the seatRequestMessage
    // ...

    Queue myPrivatePlayerQueue = myPokerSession.createTemporaryQueue();
    seatRequestMessage.setJMSReplyTo(myPrivatePlayerQueue);

    myPokerSession.send(seatRequestMessage);

In JMS terms, the temporary queue's name is not important, and is usually a generated value such as "xyz123". But by creating it and setting it as the "replyTo" field, any receivers of this message - such as the server handling the seat request - can store that temporary Queue for future direct messages to that client. Notably, the server/dealer can use this temporary queue to notify that client/player if his seat request was accepted or rejected. Securing that channel is beyond the scope of this article, but it goes without saying that security through channel name obscurity is not sufficient when critical data is being transported!

Kaazing's Enterprise Comet technology supports this API by mapping the JMS APIs to Comet transports and protocols such as Bayeux and JSON. However, the application development team gets the benefit of working against the strongly typed, yet simple, JMS standard.

A Winning Combination
Translating JMS code to Comet may not be the most obvious solution for real-time programming, but it comes with real benefits. Besides the transfer of knowledge from experienced Java EE programmers, working directly against JMS APIs allows a multitude of existing back-end messages to extend their reach into the client - and vice-versa - without forcing the client or server to undergo a mapping transformation. While JMS poker applications may not be ubiquitous, monitoring and business logic messages are. Allowing a real-time Web client to handle such messages opens up the possibility for Java Swing-based clients that talk natively to JMS to be replaced with AJAX equivalents. Or, if coexistence is preferred, an AJAX client can live alongside a Swing peer, as both will be able to communicate with the back-end business logic via JMS Destinations.

This was put to the test with our own poker application, which was largely built and tested using a simple Swing client while the AJAX client was under development. The AJAX poker application was then able to speak to the shared back end by translating the Java JMS calls to our underlying Comet support. Both client types and the server can work against the same Java Object model. Cards, players, and tables run on both tiers, but are defined and implemented once. Messages can be strongly typed, with no need to drop down to text or XML. It's a refreshing way to write a Web client.

This is only one example of how an established Java API can be integrated into AJAX client development. Due in no small part to Java's head start, the pool of Java developers vastly outnumbers those with AJAX development experience. Bridging successful Java APIs to an AJAX client is a great way to expand the pool of AJAX developers and also expand the capabilities of your applications.

Resources
  •   Comet: http://en.wikipedia.org/wiki/Comet_(programming)
  •   Java Message Service: http://java.sun.com/products/jms/
  •   Firebug: www.getfirebug.com/
  •   AJAX in ActiveMQ: http://activemq.apache.org/ajax.html
  •   Enterprise Comet: http://kaazing.com/collateral/kaazing_overview.pdf

About Brian Albers
Brian Albers has over 11 years of experience in the field of user interface technologies. Prior to joining Kaazing, Brian worked as Senior Development Manager at Oracle, where he led the planning and designing of the next generation of Oracle's UI technology, an effort publicly known as ADF Faces. During his 10 year tenure at Oracle, Brian worked primarily on mixing cutting-edge technology with large enterprise demands (internationalization, accessibility, scalability). He proposed the open source donation of ADF Faces, which ultimately became the Apache MyFaces Trinidad project. Brian led a cross-team effort to develop a DHTML rich client and a mobile client presentation layer for Oracle's upcoming Project Fusion. In his career, Brian has focused on simplifying complex UI programming models for widespread use, while maintaining backwards compatibility and keeping future flexibility, which now pays dividends in Oracle's effort to move older technologies to it's Fusion stack. Brian received a BS degree in Computer Science from the University of Texas, Austin, and a BA degree in Plan II Honors from the University of Texas, Austin.

BEA WEBLOGIC LATEST STORIES
Since its emergence, Web Service technology has gone a long way towards perfecting itself and finding its right application in the real world. With the maturity of the specifications, Web Service technology, with its power of interoperability, is now the major enabling technology of SO...
Join Scott Guthrie as he discusses Microsoft’s commitment to web standards development, Rich Internet Applications and how Microsoft is contributing to help move the web forward. Join Adobe’s Kevin Lynch as he demonstrates how Flash and HTML come together to make the most engaging,...
Virtualization has become a critical part of Enterprise IT strategy. Why and how has it become one of the most important change agents in our industry? To answer these questions I had the good fortune recently to be able to speak to a select group of top IT industry executives who join...
Watching VMware stock and its market cap spike since it IPO'd must have had Red Hat positively pea green with envyWatching VMware stock and its market cap spike since it IPO'd must have had Red Hat positively pea green with envy - so green in fact that it's gonna try taking VMware on b...
A standard from OASIS called Web Services for Remote Portlets (WSRP) is used so portlets can be decoupled from a portal. In part one (JDJ, Volume. 13, issue 3) of this article, we introduced the relevant standards and specifications and then demonstrated WSRP's capabilities by consumin...
SYS-CON's upcoming '3rd International Virtualization Conference & Expo' faculty includes such distinguished speakers as: Al Aghili (Managed Methods), Alan Chhabra (Egenera), Andi Mann (Enterprise Management Associates), Andrew Conte (APC), Andy Astor (EnterpriseDB), Ariel Cohen (Xsigo ...
SUBSCRIBE TO THE WORLD'S MOST POWERFUL NEWSLETTERS
SUBSCRIBE TO OUR RSS FEEDS & GET YOUR SYS-CON NEWS LIVE!
Click to Add our RSS Feeds to the Service of Your Choice:
Google Reader or Homepage Add to My Yahoo! Subscribe with Bloglines Subscribe in NewsGator Online
myFeedster Add to My AOL Subscribe in Rojo Add 'Hugg' to Newsburst from CNET News.com Kinja Digest View Additional SYS-CON Feeds
Publish Your Article! Please send it to editorial(at)sys-con.com!

Advertise on this site! Contact advertising(at)sys-con.com! 201 802-3021

SYS-CON FEATURED WHITEPAPERS

ADS BY GOOGLE
BREAKING NEWS FROM THE WIRES

Sun Microsystems, Inc. (NASDAQ:JAVA) today announced the new Sun SPARC(R) Enterpris...