Installation
These steps will quickly get JumpStart 3.14 to 3.20 open, running, and editable.
- Unzip. Unzip the downloaded file, which will give you a directory called jumpstart-3.14.0 or similar.
- Get JBoss Application Server.
- Go to JBoss Application Server Downloads, locate 4.2.3 GA and choose the Download link. Choose to download the jboss-4.2.3.GA.zip.
- Once downloaded, unzip it. Move it to a suitable location (eg. /devel/jboss-4.2.3.GA).
- Move JumpStart to your development projects location. Move jumpstart-3.14.0/ (or similar name) to your development area, eg. /devel/jumpstart-3.14.0/ . DO NOT choose a directory whose path contains any spaces, eg. do not use a directory whose path includes C:/Documents and Settings/.
- Open it in Eclipse. Open Eclipse and create a new Java Project over the jumpstart-3.14.0/ directory. The project can't build just yet so it will show errors.
- Ensure Eclipse is using Java 5.0. Right-click on the project and choose Properties then Java Compiler and ensure Compiler compliance level is 5.0. You may have to turn on Enable project specific settings.
- Run the get-dependent-files target
in the project's build.xml file. You can do these steps in Eclipse...
- If you haven't used Ant in Eclipse before, start by opening the Ant view and dragging build.xml onto it.
- Open the build.properties file and modify the jboss.dir property. Use a relative path eg. ../jboss-4.2.3.GA .
- If your internet connection is through a proxy then
modify the setproxy tag in build.xml, eg.
-
<setproxy proxyhost="proxy.mycompany.com"
proxyport="8080"></setproxy>
- Run the get-dependent-files target in the project's build.xml file. If it has problems due to the maven repository being slow or inaccessible, open the project's build.properties and choose a different maven.repo.root, then try running the target again.
- business/src/main/lib-compile/
- business/src/main/lib-provided/
- business/src/main/lib-runtime/
- business/src/test/lib-test/
- web/src/main/lib-compile/
- web/src/main/lib-provided/
- Refresh the project by right-clicking on the project in Eclipse and choosing Refresh. This should build the project successfully and show no errors. It will also run exploder.xml, which will build the exploded/ directory. You can see how has this been configured by displaying the project's properties and choosing Builders.
- Set exploded directory to derived by right-clicking on it in Eclipse, choosing Properties, and ticking the derived checkbox. Then click OK.
- Point JBoss at the project.
Locate the server's conf/jboss-service.xml file
eg. jboss-4.2.3.GA/server/default/conf/jboss-service.xml.
Edit it, replacing this:
-
<attribute name="URLs">
deploy/
</attribute>-
<attribute name="URLs">
deploy/, /devel/jumpstart-3.14.0/exploded/
</attribute> - Enable live web class reloading Locate the server's deploy/jboss-web.deployer/context.xml
eg. jboss-4.2.3.GA/server/default/deploy/jboss-web.deployer/context.xml.
Edit it, replacing this:
-
<Context cookies="true" crossContext="true">
-
<Context cookies="true" crossContext="true" reloadable="true">
- Ensure command line uses Java 5 JBoss 4.2.x is compatible with JDK 5 only.
In Windows and Linux, ensure that JAVA_HOME is set to a JDK 1.5 directory. Note it must be a JDK, not a JRE.
In OS X, ensure the result of java -version and javac -version is a variant of 1.5, eg. 1.5.0_13. - Start JBoss Start the JBoss server from the command line by going
to JBoss's bin/ directory and running 2 commands...
In Windows:- set JAVA_OPTS=-Dtapestry.production-mode=false -Dtapestry.compress-whitespace=false
- run.bat
- setenv JAVA_OPTS '-Dtapestry.production-mode=false -Dtapestry.compress-whitespace=false'
- run.sh
- Check JumpStart is running by pointing your web browser at http://localhost:8080/jumpstart, but don't expect to be able to log in yet.
- Drop existing tables. If you have a previous version of JumpStart already on the computer, then do this step. Otherwise, you can skip to the next step.
- Open the Hypersonic Database Manager. To do this, point your web browser at http://localhost:8080/jmx-console/, click on database=localDB,service=Hypersonic, find the section labelled void startDatabaseManager() and click on Invoke. In a few moments a Java GUI called HSQL Database Manager will start up.
- In Eclipse, locate business/src/examples/data/drop_tables.sql in the project. Open it, then copy and paste its contents into the HSQL Database Manager and click on Execute SQL.
- Stop JBoss Go to the window that is running JBoss and press Ctrl-C. Wait until JBoss has stopped.
- Start JBoss Start the JBoss server again as you did in the Start JBoss step above. This creates all the database tables automatically.
- Load initial data:
- Open the Hypersonic Database Manager. To do this, point your web browser at http://localhost:8080/jmx-console/, click on database=localDB,service=Hypersonic, find the section labelled void startDatabaseManager() and click on Invoke. In a few moments a Java GUI called HSQL Database Manager will start up.
- In Eclipse, locate business/src/examples/data/initial_data.sql in the project. Open it, then copy and paste its contents into the HSQL Database Manager and click on Execute SQL.
- Confirm JumpStart is working by returning to http://localhost:8080/jumpstart and logging in with secofr for the Login ID and secofr for the Password.
- Finished! There are 2 other users: admin and john, with passwords admin and john, respectively.
- Try making a mod! As another quick test...
- In Eclipse, locate the template of the front page -
web/src/main/java/pages/Index.tml
- and modify it a little.
If you change the template or java of a page you'll see the change just a couple of seconds later in your running application.
If you change a class in the business layer then you can make JBoss notice by running the Ant target called touch-exploded-ear in JumpStart's build.xml file. JBoss will automatically reload the app. - Remember - if the application isn't running then you can still immediately preview the mod by opening the html file with a web browser, or in Eclipse try Open With > Web Browser if that option is available. This is one of Tapestry's many strengths.
- In Eclipse, locate the template of the front page -
web/src/main/java/pages/Index.tml
- and modify it a little.
- Explore! Visit the Orientation, Tips, Troubleshooting and Bugs & Enhancements pages for more info.