Create new JBoss Tools Documentation Jira issue

This will launch the Jboss Tools Jira page - to complete your feedback please login if needed, and submit the Jira.

JBoss.orgCommunity Documentation

Chapter 12. Adding Seam support to EAR project

From this chapter you will find out how to add Seam support to EAR project

For example you have several WTP projects:

Tip

You can add as many EJBs modules as you want just doing the same for each EJB project.

WTP Projects

Figure 12.1. WTP Projects


Make sure EJB and WAR are included in EAR as modules (Properties for seamproject-ear -> Java EE Module Dependencies)

Java EE Module Dependencies

Figure 12.2. Java EE Module Dependencies


Make sure there is jboss-seam.jar in application.xml as well:

Java EE Module Dependencies

Figure 12.3. Java EE Module Dependencies


Then include libs from EAR to EJB Manifest Class-Path (Properties for seamproject-ejb -> Java EE Module Dependencies)

Including Libs from EAR to EJB Manifest Class-Path

Figure 12.4. Including Libs from EAR to EJB Manifest Class-Path


Include libs from EAR and seamproject-ejb.jar to WAR Manifest Class-Path (Properties for seamproject-war -> Java EE Module Dependencies)

Including Libs from EAR and seamproject-ejb.jar to WAR Manifest Class-Path

Figure 12.5. Including Libs from EAR and seamproject-ejb.jar to WAR Manifest Class-Path


Thus we have set our WTP EAR/EJB/WAR projects and now we are ready to add Seam support to them:

First you have to add Seam support to WAR project: Properties for seamproject-war -> Seam Settings

Adding Seam Support to WAR Project

Figure 12.6. Adding Seam Support to WAR Project


Set seamproject-war as Main Seam project. All other settings mostly are used by New Seam Entity/Action/Form/Conversation/... Wizards. Thus you can set them as you wish.

Then you can add Seam support to EJB project: Properties for seamproject-war -> Seam Settings

Adding Seam Support to EJB Project

Figure 12.7. Adding Seam Support to EJB Project


It&s important to set seamproject-war project as main Seam project there.

It will allow Seam Tools to use one common Seam model for seamproject-ejb and seamproject-war projects.

The last step is to clean/build the projects

That is all. You have added Seam support to your EAR project.

Added Seam Support to EAR Project

Figure 12.8. Added Seam Support to EAR Project