« Unit Testing Flex Application with Fluint (Flex Camp Boston 2008) | Main | How to use Flex 3 & Cairngorm with LiveCycle Data Services 2.6 (Flex Camp Boston 2008) »

Model Driven Development Using Flex Builder and LCDS "Next" (Flex Camp Boston 2008)

Model Driven Development Using Flex Builder and LCDS "Next"
Christophe Coenraets, Adobe

Only three people in audience are using LCDS, but that is part of the problem. Hard to use, hampering adoption.

Showing demo with data grid editing. Refreshing page shows changes were not lost. Two different clients against same data are synchronized. Showing multiple views of the same data. Two different companies and a search results window. Multiple view synchronization. LCDS is all about data management.

Why aren't people using it: Price shouldn't be the issue, it's all too difficult. Not focusing on server.

Currently: must create destinations (XML), create assemblers (Java), create DAO (Java), VDO (Java, AS), keep everything in sync. Don't have code completion, binding is difficult, no service introspection.

Accessing data is first hurdle. Configure server through Flex Builder wizard. Normal server properties (server name, port, context root). Can now explore data exposed by server. New "Adobe Data Model" wizard as part of project. Select server and tables you want to work with. Right now it produces XML but many have GUI later on. Including associations. Deploying data model generates code. Includes base class and subclass generation so that the base class can be regenerated without disturbing your extensions. We didn't build "demo ware" code can be used for simple to complex applications.

Dropped company list that show up as data grid. Dropping detail table in prompts for needed data based on dropped table from data model. Do have to manually write handler to connect the two data grids.

Why a custom data model? Wanted to do more than just describe data structure also wanted to define behaviors. You may have more than one data model.
Manually editing generated model to include a derived property. I.e. full name which is a combination of first and last name with some formatting. Change to data model synchronizes to other generated code.

Adding constraint to data model. Boolean variable showing valid state was added. Constraint also added to server side data model checking. Need to cast the data object in client code in order to get compile time checking that all properties are valid.

Business logic location? Can specify where a validation rule gets run. Constraint automatically would reject edit.

How it happens on the standards can't talk about how it happens yet. Is standards based, currently using Hiberante but that is subject to change.

Do you care how your data is updated in database? Will have hook before persistence but really shouldn't care about how is is saved.

Now have Flex and Spring integration. With remoting have SpringFactory that determines what method to call buts has lots of configuration today. Not really Spring like (connections are too loosely correlated as part is Sping and part is LCDS). New model is all Spring based with LCDS, easier to maintain.

Changes to schema will require refreshing the client's data model.

Tags: flex flexcampboston2008 gumbo lcds

Post a comment

(If you haven't left a comment here before, you may need to be approved by the site owner before your comment will appear. Until then, it won't appear on the entry. Thanks for waiting.)