Help

Switch Workspace

Built with Seam

You can find the full source code for this website in the Seam package in the directory /examples/wiki. It is licensed under the LGPL.

If you are interested in contributing back to Weld, please read on!

First, read this guide, it details all you need to know to set up your IDE, run the tests and to debug your work. If you are having problems, drop by #weld-dev on http://freenode.net and ask for help!

Finally, make sure there is a JIRA issue, and submit your patch. We will invite you to become a committer to Weld after a developer submits useful, well designed patches. Becoming a committer looks great on your resume, and could be the deciding factor in getting you a great job!

Red Hat Inc. also hires exceptional contributors as full-time open source developers (in fact, most of the full time team members started in the community!).

Getting Started

You first step is downloading Weld from the SVN Repository. Weld uses Maven, so run mvn install to build Weld and install it to your local maven repository. The APIs are in another project, so you'll need to check that if you have to alter them (you probably won't!).

To clean the project, type mvn clean. To show the dependencies for the project, type mvn dependency:tree.

By default, snapshot dependencies won't be updated. When you update from SVN you should also make sure that all your snapshot dependencies are up to date, using mvn -U clean install.

We require you to use Maven 2.0.10.

Setting up an Eclipse workspace

It's easy to set up an Eclipse workspace, just type mvn eclipse:eclipse in the root directory, and then use Eclipse's Import project wizard.

If you want to attach javadoc and sources to your Eclipse project, then just type mvn eclipse:eclipse -DdownloadSources -DdownloadJavadoc.

Developing Seam using IntelliJ IDEA

If you would like to use IntelliJ IDEA for Weld development, you can take advantage of the JBoss Seam community license. The license key and details about the terms are available on request.

Submitting a patch

We prefer you to submit your patch using the unified diff format. Fortunately, SVN makes this easy. Alter necessary files in the svn checkout, then run svn diff theFile.java >> mychanges.diff for each file you have changed. Then attach this file in JIRA. If you are making a lot of changes, consider splitting you changes into logical chunks. Try not to make any whitespace changes in a diff - submit a separate diff if you want to make (legitimate) whitespace changes.

Most IDEs support creating patches from SVN - for example, in Eclipse, select the file you want to create the patch from, right click, and choose Team -> Create Patch....

Running the testsuite

Weld has an extensive test suite. The test suite contains unit tests that test the RI. It also contains a test for each assertion in the spec. You should write one test for each assertion in the spec, and mark it using the @SpecAssertion(section="1.2.3") annotation. You can also use the @SpecVersion annotation to note the version of the spec you are developing the test for.

To run the whole testsuite (you should do this before submitting a patch or making a commit), run mvn clean install && mvn test -Dincontainer in the root directory, this will clean up from any previous builds, thus giving you a clean run. It will also run the entire testsuite in JBoss AS to verify the container integration. Any test failures will cause the build to fail.

To ignore test failures, you can run mvn install -Dmaven.test.failure.ignore=true.

The Weld SVN repository is checked every 15 minutes, and if changes have occured, a build is kicked off and the testsuite run. You can find the results on the Hudson monitor

Running integration tests from the TestNG Eclipse Plugin

This is useful if you want to attach a debugger to a test.

Download the TestNG Eclipse Plugin. Having installed the plugin, just right click the test file and choose Run As... TestNG test or Debug As... TestNG test.

Coding guidelines