Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 14 Next »

These instructions pertain to the current (April 2007) code in SVN

Getting the project

svn checkout https://www.ja-sig.org/svn/up3/trunk

into a directory you've created to house your uPortal 3 workspace.

That "/trunk" bit is critical – you probably don't want to check out all the tags and branches as well.

Build System

uPortal 3 uses Maven 2 as its build system. Maven 2.0.6 is recommended as of this writing and differs from earlier Maven 2.0.x versions in dependency handling.

The resulting artifact is an EAR (from the uportal3-ear sub project) that contains shared JARs, the uPortal3 WAR and WARs of pre-packaged portlets.

Not all of the dependent portlets and libraries are available in public maven repositories. For that reason there is a bootstrap sub-directory in the project which includes JA-SIG portlets and libraries and aren't yet in the JA-SIG maven repositories. There is an Ant build file in the bootstrap directory, the default target of this build file will install the included portlets and libraries into the local maven repository.

Dependencies to install manually

There are also dependencies that are not in public maven repositories and that uPortal cannot include with it. These need to be downloaded from the original distributor and installed into the local repository.

Dependency

URL

Install Command

javax.transaction:jta:jar:1.0.1B

http://java.sun.com/products/jta/
Download the 1.0.1B classes, extract and repackage as jta.jar

mvn install:install-file -DgroupId=javax.transaction -DartifactId=jta \
-Dversion=1.0.1B -Dpackaging=jar -Dfile=jta.jar

Tomcat & HSQL

Tomcat
  • Tomcat 5.5 or 6.0 is required to deploy to. Either set the CATALINA_HOME environment variable or copy build.properties.sample to build.properties and configure the tomcat location.
HSQL
  • HSQL 1.8 is required to run init-portal or init-db and run uP3. It must be listening on port 8887 and should have no existing tables in the database.
C:\hsqldb\hsqldb_1_8_0_7\hsqldb\bin>java -cp ../lib/hsqldb.jar org.hsqldb.Server -port 8887

Boot Strapping

Some dependencies are not in public repositories but are included with the uP3 code. These are in the bootstrap directory and include the necessary information for installation and an ant build to do the installation for you. Just running 'ant' from the bootstrap directory will install all of the artifacts into your local maven 2 repository, this is also done by the init-portal task.

Building uPortal 3

When working with a multi-project maven project is to initially run 'mvn install' from the base directory. This process will take a few minutes as it builds the portal source code, the uP3 WAR and the uP3 EAR. All of the built artifacts will be installed the the local repository.

mvn install

Developing with uPortal 3

If changes are only being made in a sub-project it is ok to run the maven compile/test/package goals within that sub-project. Any time development effort switches to a different sub-project mvn install should be run on the root project.

Ant utilities

deploy

Deploys the uP3 EAR to Tomcat. Requires that 'mvn package' has been run on the root of the project before running.

deploy-up3war

Deploys the uP3 WAR to Tomcat (Used when doing uP3 development). Runs 'mvn install' on the uportal3-impl and uP3 sub-projects then deploys the WAR to tomcat using the Pluto Assembler task.

init-db

Drops existing tables, creates needed tables then populates them. Requires that 'mvn package' has been run on the uportal3-impl sub-project first.

init-portal

Configures the database, deploys all resources to Tomcat. Runs the ant build in the bootstrap directory to ensure all dependencies in the local repository are up to date, run 'mvn clean' and 'mvn install' on the root of the project, calls the 'init-db' task and the 'deploy' task.

  • No labels