JavaGen.com

Petstore in 7 Weeks using MDA

The JavaGen Petstore is an e-commerce application written to demonstrate the technologies and services offered by the Outsource Cafe. It was implemented in 7 weeks by Richard Easterling, using the JavaGen code generator, which generates code from software blueprints. The process is known as Model Driven Architecture (MDA), and the blueprints are stored in a standardized format called the Unified Modeling Language (UML). Using MDA can reduce the amount of hand coding required by 50-90%. See Productivity Analysis - Model Driven Development for J2EE Utilizing a MDA Approach.

About JavaGen

JavaGen was created by the Outsource Cafe, a company that specializes in software development outsourcing services. It is used primarily in-house to develop applications for customers who prefer to outsource J2EE development or require rapid time to market.

A limited On-Line Edition of JavaGen is available on this site. You can upload UML designs and generate EJBs, DTOs, Struts forms, SQL scripts and Ant scripts (see the UML Guide).

Run Petstore Demo

Try the on-line JavaGen Petstore here. Hint: Once you're in the Petstore site, see the help page for general instructions and a list of predefined usernames and passwords.

No Toy

The JavaGen Petstore is a 6-tier J2EE distributed web application written to a published specification. It consists of client and server modules that can be deployed and tested independently. It is highly configurable and designed to be easy to modify and maintain. The Petstore has rigorous data validation, caching, logging, security, internationalization, and exception handling features. It uses CMP Entity EJB 2.0 for persistence, a sophisticated, highly scaleable, secure, database independent technology. It has a web-service-ready, XML databinding layer. And finally, because its uses Java and J2EE, the Petstore can be deployed on the platform or J2EE application server of your choosing.

In short, it's the kind of application upon which you can run a business.

JavaGen Architecture Template

Download

The JavaGen Petstore is available as source or as a prepackaged executable (ear binary) on the download page. The source is packaged in a zip file and should be extracted onto your hard drive. See Building the Source below. The binary is configured for JBoss 3.2.x and the Hypersonic database that comes pre-installed with JBoss.

Running the Binary on JBoss

Considering the level of sophistication and complexity found in J2EE applications, they are incredibly easy to install once packaged properly.

To deploy the Petstore: start JBoss (type run in the bin sub-directory), copy the ear file into the JBOSS_DIST/server/default/deploy directory by typing ant deploy and start the client by pointing your browser at http://localhost:8080/petstore.

The JavaGen Petstore requires that you install Java, JBoss, Ant, Maven and JAM as described in JavaGen Setup.

Building the Source Code

You must setup JAM and extract the JavaGen Petstore source onto your hard disk. See setup for detailed instructions. JAM files build, compile, deploy and test JavaGen applications. You can test your configuration by typing ant setup from the command line. To see all the options type ant -p. Start JBoss and make sure you've set the JBOSS_DIST environmental variable, so Ant can find JBoss's deploy directory. Once everything is properly set up, you can generate, compile, package and deploy Petstore by typing ant deploy.