You are viewing an old version of this page. View the current version.
Compare with Current
View Page History
Version 1
Current »
You can edit and test new components with Eclipse. However, it is recommended that you create the component outside of Eclipse and then to import it into the Eclipse Workspace.
- Use the Aspire/Maven archetype (aspire-stage-archetype) to create a new pipeline stage. See Creating a New Pipeline Stage (Aspire 2) for more details.
- We recommend creating the new stage within your Eclipse Workspace directory.
- After you create the stage, move the folder for the Maven project to your Eclipse Workspace.
- In Eclipse, go to File > Import.
- Choose Maven/Materialize Maven Projects for the import source.
- In Maven Artifacts to Import, remove all artifacts from the list (if any).
- Click Finish.
- You should now be given the opportunity to browse for your new stage project. Click Browse to locate your Root Directory:
- The Projects list should show the Pom file for your new stage. Make sure it's selected.
- Click Finish.
Your new stage should now be imported into Eclipse and available for Unit Testing.
- Locate the JUnit test for your component under src/test/java.
- Right-click on the unit test and select Run As/JUnit Test.
Known issues
Null Pointer Exception
In newer versions of Eclipse, after clicking Finish, the import may fail with a Null Pointer Exception due to compatibility issues in the Maven plugin.
- To fix, open the project POM and modify or add versions to the following plugins.
- After updating the POM, try to import again.
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.3</version>
<artifactId>maven-source-plugin</artifactId>
<version>2.1.2</version>
maven-bundle-plugin Error
Eclipse may reporti a problem in the pom.xml file at the start of the maven-bundle-plugin block that looks like this:
Error(s) found in manifest configuration (org.apache.felix:maven-bundle-plugin:2.3.7:bundle:default-bundle:package)
If so, build the stage from the command-line once: mvn clean install.