Coldfusion and LiveCycle Data Services

As a, sort of, justification for sending me to Max in Barcelona I have been asked to give a presentation on some of the things that I learned, heard about or otherwise experienced (minus the huge amounts of alcohol I consumed).

The four things that immediately came to mind are: CF8, AIR, Flex 3 and LCDS. Each one of these subjects really deserves their own presentation but I need to fit as much info into as little time as possible and still manage to ignite a fire under certain peoples butts and get them excited about this stuff

and hopefully be asked to present more detailed info.

While working on my presentation on Coldfusion, LiveCycle Data Services and Flex a question kept popping up. When should we use LCDS?

If you have looked at LDS you know that for each "object" you need to set up a destination in the data-management-config.xml file thats sets up the channel to communicate over. This allows two-way asynchronous communication between your front end (Flex) and back end (CF) objects. Additionally for each object you need to have and object.cfc with all your getters and setters, objectDAO.cfc that does all the data access and objectAssembler.cfc which is the interface to LDS. Thankfully there is a wizard that you can use to help create your basic files but that's not the point. Lets forget about how much "work" is involved in setting up and architecting the application for a moment and think about why you would actually need to use LDS in the first place. So I came up with the following reasons.

The Reasons to Use LCDS

  1. You need real time notifications/updates pushed to the client.
  2. You need to have conflict detection (client 1 updates record that client 2 just updated).
  3. You want asynchronous communication between the client and the server.
  4. You have "occasionally connected" clients (AIR) (not really an argument at this point as most of the folks haven't really heard of AIR..sigh).
Have I missed something?

In the above list the first three items are certainly great arguments for LCDS. Its hard to argue with the benefits to using LCDS especially in data critical applications where it is possible that one user updates a record with stale data. And naturally that ability to keep every clients data actual is also a big positive.

But we shouldn't get carried away either. We really need to think about what parts of the application need to have the data managed by LCDS and which parts can just take advantage of good old RPC (Flash Remoting). This is naturally where the correct architecting of the project comes in to play, and what technology to use and when.

In the end I think there are some definite instances where LCDS would be useful in projects were are currently working on the problem is of course that the technology decisions have already been made.

The real challenge to my presentation is to not only introduce LCDS and provide good reasons to use it, I also have to, at the same time, convince the powers that be that Flex is a viable product for us to use for our front-ends. And of course AIR to provide our customers with the ability to take their applications off-line.

All that in 60 minutes or less. Piece of cake!

4 Comments to "Coldfusion and LiveCycle Data Services"- Add Yours
Steven Erat's Gravatar You might want to expand upon where the data change occurs and what drives the notification process.

As of FDS 2/2.01 and CF 7.02, an actual user would initiate data push to other clients by adding or modifying data in their view from the Flash Player in their browser.

Now in CF8 the data can be changed programmaticaly (a scheduled task or some other CF-side call not directly tied to a user), and then if the corresponding DataManagement Gateway method was called and passed the change info, the LCDS server will be notified of the change, and then the remote user clients watching the data would in turn be notified and their view refreshed.
# Posted By Steven Erat | 11/5/07 5:00 AM
Terry Collinson's Gravatar Is there any simple example out there that shows how to use CF8 with LCDS to have data pageing in a Flex grid?
# Posted By Terry Collinson | 12/5/07 12:01 PM
Gary Gilbert's Gravatar @Terry,

The simple answer is: I haven't found one. So I will try to put one together and post it up.
# Posted By Gary Gilbert | 12/12/07 6:53 PM
Geoffrey's Gravatar Still waiting for you to post as you said you would

Is there any simple example out there that shows how to use CF8 with LCDS to have data pageing in a Flex grid?
CF8 flex 3 data push example
# Posted By Geoffrey | 7/15/08 4:20 PM

Powered By Railo

Subscribe

Subscribe via RSS
Follow garyrgilbert on Twitter Follow me on Twitter
Or, Receive daily updates via email.

Tags

adobe air ajax apple cf community cfml coldfusion examples ext flash flex google javascript jquery max2007 max2008 misc open source programming railo software technology ui

Recent Entries

No recent entries.

Blogroll

An Architect's View
CFSilence
Rey Bango
TalkingTree

Wish List

My Amazon.com Wish List