wCMF Wiki : Seam

HomePage :: Categories :: PageIndex :: RecentChanges :: Login/Register
"The JBoss Seam Framework is a powerful new application framework for building next generation Web 2.0 applications by unifying and integrating technologies such as Asynchronous JavaScript and XML (AJAX), Java Server Faces (JSF), Enterprise Java Beans (EJB3), Java Portlets and Business Process Management (BPM)."

We are currently developing a Java generator for wCMF based on the Seam framework.
The first step is to develop a Seam reference implementation of the Filmology example, which will be translated to wCMF templates in the second step.

In the following I describe the steps of creating the Filmology example with Seam:

Prerequisite: A running MySQL 4.x server with the filmology database schema.

  1. Install JBoss Application Server 4.05 with EJB 3 profile using the JEMS (JBoss Enterprise Middleware System) installer.
  2. Extract JBoss Seam 1.2.1 in an arbitrary directory. Configure Seam as described in the documentation and run ANT.
  3. Go to the Seam directory and run seam setup to configure seam (e.g. Database Connection).
  4. Type seam new-project to create an eclipse workspace skeleton.
  5. Type seam generate-entities to generate a CRUD application from the database schema.
  6. Type seam explode to deploy an exploded EAR of the generated application on the JBoss AS.

Now you can use the CRUD application, which is typically running at http://localhost:8080/application-name

When using the application you will notice that the associations between the tables are not generated correctly. There is no link between the tables, instead the foreign keys are listed as normal columns. This is because the standard Filmology schema has no constraints, in the PHP generator those are implemented in PHP classes.
To fix this I have extended the schema definition with the foreign key constraints. (You can find the schema insided the filmology workspace in the subversion repository, inside the sql directory).
When using this schema and running seam generate-entities again (and seam restart), the CRUD application is generated (almost) as expected.

Comparing the generated PHP application and the generated Seam application, I have discovered the following functional differences, on which I am working to get a similar Java based filmology example:

Valid XHTML 1.0 Transitional :: Valid CSS :: Powered by WikkaWiki
Page was generated in 0.0238 seconds