Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Won't Fix
-
2.5.1
-
None
-
None
Description
There is an issue generating wtp configuration for multi-module j2ee applications that use connectors.
Suppose you have a "connector project" to access an external data source packaged as a RAR (Resource Archive) and an Eclipse "enterprise application project" with packaging EAR.
The EAR includes the RAR between its dependencies. Below you can see the correct EAR structure as deployed by maven:
myapp.ear
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
here is a snippet from: myapp/jcr-connector/pom.xml
<project>
<artifactId>myapp-jcr-connector</artifactId>
<packaging>rar</packaging>
...
here is a snippet from: myapp/ear/pom.xml
<dependency>
<groupId>${pom.groupId}</groupId>
<artifactId>myapp-jcr-connector</artifactId>
<version>${pom.version}</version>
<type>rar</type>
</dependency>
When the wtp configuration of the "Enterprise Application Project" is generated the "Connector Project" is not referenced in the org.eclipse.wst.common.component (of the Enterprise project) file thus making the deployment of the connector artifact fail.
By the way the connector it's not included in the generated application.xml too, but this file can be easily overridden.
Here is how the rar should be referenced in the application.xml:
<module id="ConnectorModule_1203933609087">
<connector>myapp-jcr-connector.jar</connector>
</module>
...