SeamFramework.orgCommunity Documentation

Chapter 2. Generating a basic Java EE web-application

2.1. First steps with Scaffolding

For the most part, people interested in Forge are likely interested in creating web-applications. Thusly, this chapter will overview the basic steps to generate such an application using Forge.

Assuming you have already completed the steps to install Forge, the first thing you'll need to do is download and install JBoss Application Server 6.0. This server will host your application once is is built.

Next, follow these steps to create your skeleton web-application; be sure to replace any {ARGS} with your own personal values. Also keep in mind that while typing commands, you may press <TAB> at any time to see command completion options:

  1. Execute $ forge from a command prompt.
  2. Create a new project:
    $ new-project --named {name} --topLevelPackage {com.package} --projectFolder {/directory/path}
  3. Install the web-scaffold facet, and press ENTER to confirm installation of required facet dependencies and/or packaging types:
    $ scaffold setup 
  4. That's it! Now in a separate command shell, build your project using Maven, and deploy it onto your JBoss Application Server instance:
    $ mvn clean package
    $ mvn jboss:hard-deploy
    $ mvn jboss:start
  5. Access your application at: http://localhost:8080/{name}-1.0.0-SNAPSHOT/