Comments
Richard Davies wrote: The UK has a good crop of technology pioneers in cloud computing - for example ElasticHosts, FlexiScale, Flexiant, OnApp - and also some strong government initiatives such as G-Cloud. We will have to see whether this kind of technical leadership converts into swift mass-market adoption or not.
Cloud Expo on Google News


2008 West
DIAMOND SPONSOR:
Data Direct
SOA, WOA and Cloud Computing: The New Frontier for Data Services
PLATINUM SPONSORS:
Red Hat
The Opening of Virtualization
GOLD SPONSORS:
Appsense
User Environment Management – The Third Layer of the Desktop
Cordys
Cloud Computing for Business Agility
EMC
CMIS: A Multi-Vendor Proposal for a Service-Based Content Management Interoperability Standard
Freedom OSS
Practical SOA” Max Yankelevich
Intel
Architecting an Enterprise Service Router (ESR) – A Cost-Effective Way to Scale SOA Across the Enterprise
Sensedia
Return on Assests: Bringing Visibility to your SOA Strategy
Symantec
Managing Hybrid Endpoint Environments
VMWare
Game-Changing Technology for Enterprise Clouds and Applications
Click For 2008 West
Event Webcasts

2008 West
PLATINUM SPONSORS:
Appcelerator
Get ‘Rich’ Quick: Rapid Prototyping for RIA with ZERO Server Code
Keynote Systems
Designing for and Managing Performance in the New Frontier of Rich Internet Applications
GOLD SPONSORS:
ICEsoft
How Can AJAX Improve Homeland Security?
Isomorphic
Beyond Widgets: What a RIA Platform Should Offer
Oracle
REAs: Rich Enterprise Applications
Click For 2008 Event Webcasts
SYS-CON.TV
Top Links You Must Click On


Real-World Adobe Flex Tips, Tricks and Techniques
Tips, Tricks and Techniques From Adobe's Intrepid Senior Evangelist For Rich Internet Applications

(July 14, 2006) - Some people take the dog for a walk, others go play a round of golf. Not Christophe Coenraets. His idea of a good time is to illustrate Flex 2 / JMS integration by extending a simple "realtime feed" application that he built a while back! Web Developer's & Designer's Journal is proud to bring you each month two of the month's best tips from Adobe's intrepid Flex Hero.

Flex and JMS: Real Time Market Data Application
The Message Service at the core of the Flex Data Services (http://labs.adobe.com/technologies/flexdata_services2/) is one of the important new features in Flex 2. (see Figure 1)

Unlike JMS, the Flex Message Service provides an actual implementation of a publish/subscribe messaging system, not just an API. It might be all you need for simple, self contained use cases where you just want to exchange messages between Flex clients. In Enterprise integration scenarios, the Flex message service integrates with, and extends existing messaging systems to allow thin clients to publish and subscribe to topics these systems manage. Flex integrates with existing messaging systems through an adapter architecture. Using the JMS adapter available out-of-the box, you can map Flex destinations to JMS topics. For example, the snippet below (added to flex-message-service.xml) defines a destination called "stock-feed", and maps it to a JMS topic called "FlexTopic".

<destination id="stock-feed">
   <properties>
     <server>
     <durable>false</durable>
       <durable-store-manager>flex.messaging.durability.FileStoreManager</durable-store-manager>
     </server>
     <jms>
       <destination-type>Topic</destination-type>
       <message-type>javax.jms.TextMessage</message-type>
       <connection-factory>jms/flex/TopicConnectionFactory</connection-factory>
       <destination-jndi-name>jms/topic/flex/simpletopic</destination-jndi-name>
       <destination-name>FlexTopic</destination-name>
       <durable-consumers>false</durable-consumers>
       <delivery-mode>NON_PERSISTENT</delivery-mode>
       <message-priority>DEFAULT_PRIORITY</message-priority>
       <acknowledge-mode>AUTO_ACKNOWLEDGE</acknowledge-mode>
       <transacted-sessions>false</transacted-sessions>
     </jms>
   </properties>
   <channels>
     <channel ref="my-rtmp"/>
   </channels>
   <adapter ref="jms"/>
</destination>

This mapping allows Flex clients to publish and subscribe to the JMS topic. For example, the following line of code is all you need in your Flex client to subscribe to the "stock-feed" destination:

<mx:Consumer id="consumer" destination="stock-feed" message="messageHandler(event)"/>

To illustrate the Flex and JMS integration, I recently spent some time extending the simple "realtime feed" application that I built a while back as a sample shipping with the Flex Data Services. This new version looks more like a real trading application: A Java application publishes simulated real time market data to a JMS topic. The Flex client subscribes to that topic and displays the data in a DataGrid and in a Line Chart that are updated in real time.

Action Points

Flex and AJAX: Google Maps Collaboration
As an example of AJAX/Flex integration, I built a simple collaboration module that you could add on top of any AJAX (or Flex) application. In this example, I chose to add it on top of Google Maps. (see Figure 2)

The Flex module adds the following collaboration features to Google Maps:

  1. Map sharing: Maps are kept in sync (in real time) between users involved in a collaboration session.
  2. Videoconferencing (Webcam sharing and VOIP): You can share your Webcam and microphone to add video and audio to your collaboration session.
  3. Whiteboarding: Collaborating users can draw on the map. For example you could draw potential directions, etc. The users' whiteboards are kept in sync in real time.
  4. Cursor sharing: When you move your mouse, other users see the movements of your mouse and what you are pointing at.
The Flex features used in this example include:
  1. Publish/subscribe messaging and support for real-time communication
  2. Drawing API
  3. Support for Webcam/voice capture and streaming (Flash Media Server is required for streaming).
Action PointsThis application requires the Flex Data Services for pub/sub messaging, and the Flash Media Server for media streaming.

About Christophe Coenraets
Christophe Coenraets currently works as a Senior Technical Evangelist at Adobe. Before joining Adobe, Christophe was an evangelist at Macromedia, focusing on Rich Internet Applications and Enterprise integration. Prior to Macromedia, Christophe was the head of Java and J2EE Technical Evangelism at Sybase, where he started working on Java Enterprise projects in 1996. Before joining Sybase in the US, Christophe held different positions at Powersoft in Belgium, including Principal Consultant for PowerBuilder, and Manager of the Professional Services organization. Before joining Powersoft, Christophe worked as a developer and architect on several retail and BPM projects. Christophe has been a regular speaker at conferences worldwide for the last 10 years.

In order to post a comment you need to be registered and logged in.

Register | Sign-in

Reader Feedback: Page 1 of 1

Nice post, but could you please fix the examples. Both links give a 404 error!

Cheers

I got an 404 error while clicking on the link :(

Please update it!

Cheers!
Anupam

The links for the examples(both JMS and Maps) are not accessible ....

Some people take the dog for a walk, others go play a round of golf. Not Christophe Coenraets. His idea of a good time is to illustrate Flex 2 / JMS integration by extending a simple 'realtime feed' application that he built a while back! Web Developer's & Designer's Journal is proud to bring you each month two of the month's best tips from Adobe's intrepid Flex Hero.

Some people take the dog for a walk, others go play a round of golf. Not Christophe Coenraets. His idea of a good time is to illustrate Flex 2 / JMS integration by extending a simple 'realtime feed' application that he built a while back! Web Developer's & Designer's Journal is proud to bring you each month two of the month's best tips from Adobe's intrepid Flex Hero.


Your Feedback
Roelof wrote: Nice post, but could you please fix the examples. Both links give a 404 error! Cheers
Anupam wrote: I got an 404 error while clicking on the link :( Please update it! Cheers! Anupam
Abhishek wrote: The links for the examples(both JMS and Maps) are not accessible ....
Web Developer's & Designer's Journal wrote: Some people take the dog for a walk, others go play a round of golf. Not Christophe Coenraets. His idea of a good time is to illustrate Flex 2 / JMS integration by extending a simple 'realtime feed' application that he built a while back! Web Developer's & Designer's Journal is proud to bring you each month two of the month's best tips from Adobe's intrepid Flex Hero.
Web Developer's & Designer's Journal wrote: Some people take the dog for a walk, others go play a round of golf. Not Christophe Coenraets. His idea of a good time is to illustrate Flex 2 / JMS integration by extending a simple 'realtime feed' application that he built a while back! Web Developer's & Designer's Journal is proud to bring you each month two of the month's best tips from Adobe's intrepid Flex Hero.
Enterprise Open Source Magazine Latest Stories . . .
Apache Deltacloud, the Red Hat-contributed ReSTful API that abstracts differences between clouds so services on any cloud can be managed – provided of course there’s a driver – has graduated from the Apache Foundation’s incubator and is now a full-fledged Top-Level Project (TLP). The...
With Cloud Expo 2012 New York (10th Cloud Expo) just four months away, what better time to start introducing you in greater detail to the distinguished individuals in our incredible Speaker Faculty for the technical and strategy sessions at the conference... We have technical and st...
AMD said late Tuesday that its chief sales officer Emilio Ghilardi had left the company and that CEO and president Rory Read is going to do his job while a replacement is sought. AMD didn’t say why Ghilardi left but it’s assumed Read wants his own people. Read is relatively new to th...
During the lifespan of M3 (Monitis Monitor Manager) there has always been something lacking – timers. M3 execution procedure was outlined in this previous article. The execution mentioned in the latter was a one-time-execution, whereas server monitoring requires periodic invocati...
Red Hat is putting its bought-in Gluster scale-out NAS storage technology, acquired in October, on the Amazon cloud. It’s styled Red Hat Virtual Storage Appliance for Amazon Web Services and other clouds are supposed to follow in short order.
A new episode of the screencast series is now available at the OpenNebula YouTube Channel. This screencast demonstrates the new easily-customizable self-service portal for cloud consumers. Its aim is to offer a simplified access to shared infrastructure for non-IT end users. The scree...
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