Skip to end of metadata
Go to start of metadata

 

You will need Maven 3 to build the project from the source code. (In the case you don't have maven 3, you can get it from maven official website.)

 

Right now, the project is in two. The common platform called OpenNaaS, and features plug-ins aggregated under the name of mantychore.

Mantychore depends on, and extends, OpenNaaS. However, maven should resolve this dependency, and allow plug-in developers to stay away of opennaas.

Currently, there's an undesired behavior in plug-ins integration tests that forces the developer to have opennaas installed in its local repository for the tests to pass.

Meanwhile this behavior is fixed, the developer needs to build opennaas project one time before building mantychore.

 

 

In order to build the project, go to the root of the project and tell maven to do so by typing:

mvn clean install

This will cause maven to download all required dependencies, install them to your local repository and build our application.

Populating your local repository with all required dependencies may take its time, especially the first time you do it.

By default, installing the application will cause all tests to run, which can take around an hour.

 

Tips and tricks

Skip Tests

If you want to build the project but skip the tests, you can do so using

mvn clean install -DskipTests

Given flag will cause maven not to run tests, but tests will be compiled anyway.

Resume from a given point

If you want to build artifacts starting in a specific one (useful after fixing an error in that artifact), use:

mvn clean install -rf :<artifactId>

Do not stop at first failure

Maven stops building the project when a tests suite fails. To force maven to keep on building and testing use the "fail never" flag:

mvn clean install -fn

At the end of the building process, a summary of the execution will show you per artifact results.

Adding memory to maven

Depending on your system specifications, you may need to increase the amount of memory maven can use to compile the project.

Typical related errors are:

  • Java heap space
  • PermGen space

Apache Maven project has this web that may help to solve the problem.

Labels: