That has helped a lot - was not aware of the <type> in <dependency>.
Regarding not having to include <type>ejb-client</type>: I think generateClient is false for the ejb goal. Anyway, I have my client interfaces in a separate project (and I think as long as deployed in the same ear and referenced through Class-Path this is still ok with the spec ..). So I tried with to add my client module with either 1) <type>ejb-client</type> in the dependency, and get Missing: ---------- 1) winterthur.jackpot.sample:sample-ejb-client:ejb-client:client:1.0-SNAPSHOT 2) <type>jar</type> in the dependency and <modules> <javaModule> <groupId>winterthur.jackpot.sample</groupId> <artifactId>sample-ejb-client</artifactId> </javaModule> </modules> where the java client module is not added to the generated application.xml Any ideas? Thanks a lot again. Simon -----Ursprüngliche Nachricht----- Von: Kenney Westerhof [mailto:[EMAIL PROTECTED] Gesendet: Mittwoch, 19. April 2006 18:18 An: Maven Users List Betreff: Re: AW: M2: Assembling modules in an ear On Wed, 19 Apr 2006, Gunzenreiner Simon wrote: > Hi Kenny > > Thanks a lot. I removed the <modules> config, and set generateApplicationXml > to true. Please find my pom.xml attached. Now the ear is created with the > dependent libraries, but the generated application.xml is simply > > <?xml version="1.0" encoding="UTF-8"?> > <!DOCTYPE application PUBLIC > "-//Sun Microsystems, Inc.//DTD J2EE Application 1.3//EN" > "http://java.sun.com/dtd/application_1_3.dtd"> > <application> > <display-name>sample</display-name> > </application> > > I expected it to list my ejb module. Ok. Normal 'jar' dependencies are NOT added to the EAR by default; for those you need to specify a <modules><javaModule> (and add them as a dependency). Next, you don't seem to add any J2EE jars at all - the dependencies don't specify a <type> tag. If you want to include a .war you have to specify <type>war</type> for the dependency. If you want to include an ejb archive you need to specify <type>ejb</type>. You should NOT include any ejb-client (<type>ejb-client</type>) dependencies: if you have a project with <packaging>ejb</packaging>, the contents of the ejb-client version are already present in the main ejb artifact. That is a J2EE requirement: the bean implementations and the local/home/remote interfaces should all be in one jar. That said, I don't think you'll need to include any jars at all. Hope this helps a bit! -- Kenney > > Thanks, > Simon > > -----Ursprngliche Nachricht----- > Von: Kenney Westerhof [mailto:[EMAIL PROTECTED] > Gesendet: Mittwoch, 19. April 2006 17:41 > An: Maven Users List > Betreff: Re: M2: Assembling modules in an ear > > > On Wed, 19 Apr 2006, Gunzenreiner Simon wrote: > > - Drop the <scope>compile</scope> - it's the default anyway, and not > needed for compilation of the ear > > - the modules section is only needed for modules that need special > configuration, like a war module usually gets a contextRoot > > - do you provide your own application.xml somewhere or do you use the > GenerateApplicationXmlMojo? > > - Did you specify the configuration at the global level or in executions? > > If you could paste your plugin configuration in the mail, that would be > helpful. > > -- Kenney > > > I am trying to create an ear by assembling multiple other projects in Maven > > 2.0.4. My ear config files are located in a separate project with > > <packaging>ear</packaging>. All dependent projects are listed as > > <dependency> with scope <scope>compile</scope>. In addition, I added the > > <modules> configuration as described here: > > http://maven.apache.org/plugins/maven-ear-plugin/howto.html. > > > > I am facing two problems now: > > - I get an Error message if I add my EJB project to the <modules> list: > > Artifact[myGroupId:sample-ejb:ejb] is not a dependency of the project. > > although I added this project to the dependency list as well as to the > > module list. > > - Java (client) modules are not added to the generated application.xml > > > > Any hints really appreciated. > > > > Thanks > > Simon > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Kenney Westerhof http://www.neonics.com GPG public key: http://www.gods.nl/~forge/kenneyw.key --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]