Hi,
Thanks for your responses. The first solution (only 2 war) didn't work.
Compile failed for the final web application, as framework classes were
not found.
I tried to break framework in 2 modules :
my_apps
-->pom.xml
-->framework-classes/
---|-->pom.xml
-->framework-webapp/
---|-->pom.xml
-->isf/
---|-->pom.xml
isf depends on framework-webapp and framework-classes.
isf and framework-webapp are war projects. framework-classes is a jar.
Finally, I obtain a isf.war with all that is needed. So I think it's a
working solution, even if it's a bit messy to break framework in 2
parts. I will take a look at the dependency plugin now.
Thanks again.
Julien
On 4/10/06, Eric S. <[EMAIL PROTECTED]> wrote:
Hi,
you can use the war dependency like this :
web framework POM :
<project>
<groupId>sample</groupId>
<modelVersion>4.0.0</modelVersion>
<artifactId>web-fwk</artifactId>
<packaging>war</packaging>
<version>0.9-SNAPSHOT</version>
<name>Web Framework</name>
</project>
web final POM
<project>
<groupId>sample</groupId>
<modelVersion>4.0.0</modelVersion>
<artifactId>web</artifactId>
<packaging>war</packaging>
<version>0.9-SNAPSHOT</version>
<name>Web</name>
<dependencies>
<dependency>
<groupId>sample</groupId>
<artifactId>web-fwk</artifactId>
<version>0.9-SNAPSHOT</version>
<type>war</type>
<scope>compile</scope>
</dependency>
Does this really work? Maven will compile against all the jars in
WEB-INF/lib and the classes in WEB-INF/classes? Is this documented
somewhere?
</dependencies>
<build>
<finalName>${project.artifactId}</finalName>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>2.0-beta-3-SNAPSHOT</version>
<executions>
<execution>
<phase>generate-sources</phase>
<goals>
<goal>exploded</goal>
The 'exploded' goal will try to *build* the exploded war, though, not just
explode it. I doubt that's what you'd want. More likely, you'd want to use
the dependency plugin to unpack the war. See:
http://mojo.codehaus.org/dependency-maven-plugin/unpack-mojo.html
--
Martin Cooper
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
This will exploded all war dependencies into your target directory and
classes of all war will be in the classpath.
Eric
--
View this message in context:
http://www.nabble.com/Setting-up-complex-webapp-t1425211.html#a3844842
Sent from the Maven - Users forum at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--
_________________________________________________________________________
Julien HENRY | **Capgemini Sud **| Nice
www.fr.capgemini.com <http://www.capgemini.com/>
Porte de l’Arénas – Entrée B | 455 Promenade des Anglais | 06200 Nice
**Join the Collaborative Business Experience**** **
_________________________________________________________________________
This message contains information that may be privileged or confidential and is
the property of the Capgemini Group. It is intended only for the person to whom
it is addressed. If you are not the intended recipient, you are not authorized
to read, print, retain, copy, disseminate, distribute, or use this message or
any part thereof. If you receive this message in error, please notify the
sender immediately and delete all copies of this message.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]