|Deploying project dependencies [message #214848]
||Wed, 04 June 2008 15:24
Originally posted by: Kevin.REMOVE.Dean.datadevelopment.com|
Asking again, slightly differently this time...
I have the following projects in an Eclipse workspace:
- Base-Data (base data objects)
- Base-EJB (base EJB constructs, not deployable, depends on Base-Data)
- MyApp-Data (application-specific data objects, depends on Base-Data)
- MyApp-EJB (application-specific EJB constructs, part of deployable EAR,
depends on all of the above)
- MyApp (EAR)
One of the EJB constructs in Base-EJB is a class called BaseSessionBean.
This class contains a number of utility methods that are designed to make
life a little easier for the multiple EJB projects we're creating.
The Base-EJB project also contains common entity classes. Data tables like
Country, Region, and Language are common across all applications so I want
to put their JPA entity beans into a common project.
The problem is that no matter how I setup MyApp-EJB (except as below), the
classes from the dependencies simply won't be added to the EJB JAR file
and the deployment to Glassfish fails due to missing classes
(BaseSessionBean being the one that ends up in the error log).
The only way to get it to work is to use the "Link Source..." button on
the "Source" tab of "Java Build Path" in the project properties. This
causes another problem: changes made in Base-EJB or any of the other
dependencies aren't detected in MyApp-EJB and so a build doesn't pick them
up. I have to refresh MyApp-EJB every time I make changes in the base.
What is the recommended way in Eclipse to setup project dependencies so
that the generated class files are included in the final deployable JAR?
Powered by FUDForum
. Page generated in 0.26196 seconds