Click here to Skip to main content
Click here to Skip to main content

The Application Automation Layer: Introduction And Design

, 25 Dec 2002
Rate this:
Please Sign up or sign in to vote.
This introduction lays the foundation for a framework that promotes a consistent design and coding style for large-scale, multi-developer projects and results in applications that are responsive to requirement changes, easily updated and easily debugged.

The Application Automation Layer: Introduction And Design

This introduction lays the foundation for the concepts behind the Application Automation Layer (AAL). Because this article is long enough just discussing concepts, there is no example code here--a considerable amount of code already exists in other articles that I've written. I am currently setting up a SourceForge site for public access. Future articles will discuss the AAL implementation itself and use a demonstration project (photo album organizer) to illustrate its use.

What Is Wrong With Object Oriented Development?

Objects are often interconnected. It makes for a pretty object model diagram, but class re-use is all but impossible because of the interdependencies between objects. This results in slow builds, cascading side effects when code is changed, and complex testing.

In many designs, objects insufficiently abstract the concepts that they are trying to represent. This introduces “rigidity” into an application. The less abstract an object is, the more difficult it becomes to change its behavior. Applications become inflexible to requirement changes and new technologies, and become unresponsive to market changes.

Why Do We Need An Application Automation Layer?

  1. Design, development and testing of large scale applications is too expensive;
  2. The longer a development effort takes, the more likely the requirements will have changed, either as a result of customer requirement changes, technology changes, or competition;
  3. Design and implementation methodologies vary greatly across a multi-team project, resulting in code sharing and maintenance problems. A framework that promotes a consistent design and implementation philosophy reduces this difficulty;

Does The AAL Benefit Small-Scale Application Development?

  1. Many small-scale, single developer applications embrace multiple technologies. The AAL reduces the time it takes to hook these technologies together and to add a new technology that interfaces with existing ones.
  2. By starting with a framework that promotes re-use, an application that appears to be small-scale can migrate to a large-scale effort without redesigning and rewriting code;
  3. Rapid prototyping.

What Are The Advantages Of The Application Automation Layer?

  1. Build projects with debugged and tested components;
  2. Built in instrumentation allows tracing of all events;
  3. Component-based development;

Has This Concept Been Implemented And Tested In The Real World?

Yes. A brief description of three projects (of many) that currently use the AAL as implemented in C++/MFC:

  1. Automation Of Satellite Design: A large-scale, multiple developer, three year project to automate the design of communication relay satellites.
  2. Boat Yard Workflow Management: A medium-scale, single developer, multi-year project to manage the workflow of boat yard operations—work orders, job tracking, inventory, payroll and customer billing. The AAL framework allows the support of custom data representation and workflow processes for different boat yards, while retaining the same code base.
  3. Club Management: A medium-scale, single developer, multi-year project managing the income of adult entertainment clubs and entertainers. This system utilizes complex scheduling, threading and inter-process communication.

What Does The Application Automation Layer Do?

Primarily, the AAL consists of several technologies:

  1. A Data Hub
  2. A Process Manager
  3. A Component Manager
  4. Instrumentation Package

Additional features of the AAL are considered “technology components” and are not discussed in this article. These include:

  1. GUI Controls
  2. Database Interface
  3. State Manager
  4. Additional technology component interfaces

Data Hub

The data hub provides a common data exchange mechanism between technologies that have different data representation schemes. The classical approach is illustrated in this figure:

Here, the application has an application-to-technology specific interface for data. Using the AAL, the data exchange occurs as follows:

For example, a typical application is responsible for reading a record set in to a database and reformatting it for a particular GUI control. If instead the AAL concept is used, the application instructs the database technology to load the record set. This record set is translated, by the database technology, into a common data representation. The application then instructs the GUI control to display this information. The GUI control extracts the common data representation and formats it to the particular requirements of the control.

Furthermore, the concept of loading a record set has been sufficiently abstracted by the database technology that it can handle a generic record set specified by a SQL statement, for example. Many applications seem to embed record specific functionality. This makes the application inflexible to requirement changes. The point here is that while the programmer can still do it “the wrong way”, there is now a technology that promotes (if not enforces) a better approach.

The concept of a common data representation is also used by the C#, Visual Basic and other compilers—all code is compiled into a common code language.

Process Manager

The process manager decouples unrelated objects by using a meta-interface. This reduces build time dependencies and problems related to changes in object designs, as described above. The process manager is implemented as a script engine that directs the acquisition, exchange, manipulation and deposition of data.

Processes are typically initiated by events, and of those, typically GUI events such as clicking on a button or selecting a list. Therefore, to take full advantage of the process manager, the Forms plug-in technology interfaces with the process manager in response to GUI initiated events. And as illustrated in the above diagram, the Forms plug-in interfaces with the Data Hub. These two concepts create a powerful combination that decouples GUI driven processes from the specific GUI. This is one of the fundamental steps in designing a program to be more flexible to requirement changes. I’ve seen too many applications where the “processing” is part of the “OnClick” handler of a button!

For example, consider the typical process flow that an application takes to load a GUI control with a record set, as illustrated in this diagram:

Versus the process flow an application would take with the AAL:

Notice that in this diagram, the “application” (in the literal sense, any C# specific code) is not used. The process manager is based on the event manager described in my article An instrumented synchronous/asynchronous event manager [^].

Component Manager

The component manager promotes component-based development. The application itself is considered another technology which is merely another plug-in to the framework. The component manager is responsible for loading and unloading of technology components and the registration of the component’s public interface.

Instrumentation

A fallout of this scheme is that an application is automatically instrumented—data exchanges, event invocation, object to object messaging all include instrumentation, so that it is very easy to trace an application. The AAL includes an instrumentation package (see my article on C# Debug And Trace Classes [^]).

What About Agile Programming and eXtreme Programming?

The AAL is an implementation of a framework that supports these project development styles. AP and XP are excellent ideals that can only be achieved by implementing a framework such as the AAL. The AAL has been proven to be effective in its goals, even before the concepts of AP and XP existed.

Conclusion

In the next couple of articles, I will present the implementation for the four components I discussed above. I hope no one gets upset that there isn’t any code in this article. I intended this article to present the foundational design concepts without getting mired in specific implementation issues. As a side note, I am also planning to integrate the concepts that I presented in my Organic Programming article [^] with the concepts in the AAL.

As I mentioned before, I am currently in the process of setting up a SourceForge site to support this effort. However, if you want a sneak peak at some prototype code, see my recent article on Fractal Trees [^].

Given this overview, I am interested in feedback from the programming community. And anyone who is interested in working on this project, please let me know!

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

Share

About the Author

Marc Clifton

United States United States
Marc is the creator of two open source projets, MyXaml, a declarative (XML) instantiation engine and the Advanced Unit Testing framework, and Interacx, a commercial n-tier RAD application suite.  Visit his website, www.marcclifton.com, where you will find many of his articles and his blog.
 
Marc lives in Philmont, NY.

Comments and Discussions

 
GeneralCool! ... Some Thoughts Pinmembergniemcew11-Sep-04 6:50 
GeneralRe: Cool! ... Some Thoughts PinprotectorMarc Clifton11-Sep-04 7:27 
GeneralRe: Cool! ... Some Thoughts Pinmembergniemcew19-Sep-04 5:40 
GeneralWorkflow Manager PinmemberDavid J Tasker29-Aug-03 6:19 
GeneralRe: Workflow Manager PineditorMarc Clifton29-Aug-03 8:00 
GeneralWorkflow Manager PinmemberDavid J Tasker29-Aug-03 6:17 
GeneralSoftware Development on a Leash PinmemberMtnBiknGuy8-Jun-03 6:49 
GeneralRe: Software Development on a Leash PinsubeditorMarc Clifton8-Jun-03 11:06 
The author describes separating the application from the architecture, and while I've done this before in software on several levels, I never considered removing the application completely from the compiled software and driving application behavior from what the author calls "external structural and behavioral metadata". Using the same binary program to support multiple applications without recompiling a single line of code? Perhaps without recompiling on each and every application release, which makes perfect sense. However, he avoids rebuild for complex screen-level changes, too (even cosmetics). Not too shabby.

 
Sounds like what I've achieved with the MFC version, but my approach is different--I don't use metadata and object builders. I must confess I haven't read the book, so my response here is limited to reading the reviews. I'll have to get a copy of it though, it looks interesting.
 
Regarding your comment in the 4th article--several people so far have pointed me to the Sharp Develop project. I really need to contact these people!
 
Thanks for the feedback and the references--it's really helpful to network with other people.
 
As to the Source Forge site, it's an area I've completely ignored after the initial burn of reading through all the Unix-style documentation and finally managing to get something up and running on CVS. If you'll pardon the metaphor, it's a satellite in a LEO that's awaiting the next burn to the transfer orbit.
 
I do have an MSI installation with the latest and greatest though, that I could email you, if you were interested. Know anyone that can help me set up the CVS stuff on Source Forge?
 
Thanks!
 
Marc
 
Help! I'm an AI running around in someone's f*cked up universe simulator.
Sensitivity and ethnic diversity means celebrating difference, not hiding from it. - Christian Graus
Every line of code is a liability - Taka Muraoka
Microsoft deliberately adds arbitrary layers of complexity to make it difficult to deliver Windows features on non-Windows platforms--Microsoft's "Halloween files"

GeneralRe: Software Development on a Leash PinmemberMtnBiknGuy8-Jun-03 13:18 
GeneralRe: Software Development on a Leash PinsubeditorMarc Clifton8-Jun-03 13:35 
GeneralRe: Software Development on a Leash PinmemberMtnBiknGuy9-Jun-03 7:16 
GeneralRe: Software Development on a Leash PinsussJack Maher22-Oct-03 6:11 
GeneralRe: Software Development on a Leash PinmemberMtnBiknGuy23-Oct-03 8:25 
GeneralSome comments PinmemberDavidIzadaR30-Apr-03 10:11 
GeneralA newbie OOPS programmers moment of weakness ... PinsussAnonymous25-Mar-03 19:53 
GeneralRe: A newbie OOPS programmers moment of weakness ... Pinmemberpeterchen1-Apr-03 11:16 
GeneralMore please PinmemberMichael P Butler31-Dec-02 10:05 
GeneralRe: More please PinmemberMarc Clifton31-Dec-02 12:35 
GeneralObject Oriented Programming PinmemberRon Marshall31-Dec-02 9:39 
GeneralRe: Object Oriented Programming PinmemberMarc Clifton31-Dec-02 11:08 
GeneralRe: Object Oriented Programming PinmemberRon Marshall2-Jan-03 4:57 
GeneralRe: Object Oriented Programming PinmemberMarc Clifton2-Jan-03 5:33 
GeneralRe: Object Oriented Programming PinmemberMarc Clifton2-Jan-03 7:08 
GeneralRe: Object Oriented Programming PinmemberRon Marshall2-Jan-03 10:47 
GeneralRe: Object Oriented Programming PinmemberMarc Clifton3-Jan-03 1:47 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Mobile
Web02 | 2.8.140814.1 | Last Updated 26 Dec 2002
Article Copyright 2002 by Marc Clifton
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid