I should have copied and pasted - I've got the editor open on my work windoze box, and GMail on my Mac
On Tue, Mar 15, 2011 at 11:00 AM, Yegor Bugayenko <[email protected]> wrote: > Try to rename <dependancies> to <dependencies>. > > — > Yegor Bugayenko > > > > On Tue, Mar 15, 2011 at 3:56 PM, Dave Levitt <[email protected]> wrote: >> >> I am having trouble using the ear plugin [version 2.5] with Maven >> 3.0.3, to create an EAR file for a simple stateless ejb. >> >> I've tried the javaee 6 archetype from mojo - that seems to be just >> for the ear module of a multi-module application - accordingly, I've >> tried both single and multi module configurations but so far neither >> has worked. I've tried following an example I've located at >> >> http://agoncal.wordpress.com/2009/10/23/because-i-always-forget-how-to-use-maven-ear-plugin/ >> but I'm getting an empty ear file >> >> I want to create a complete example that could be added to the usage >> page for the plugin. >> >> So, assuming that we want to package one java ee 6 Stateless Session >> Bean [annotated @Stateless, one public method returning a fixed >> String] like >> >> package org.apache.maven.example; >> >> import javax.ejb.Stateless; >> >> @Stateless >> public class Foo{ >> public String getTest(){ >> return "test"; >> } >> } >> >> And assuming that a multi module layout is used [parent, ejb module, >> ear module] what should the pom for the ear module look like? >> >> My [non working] example currently looks like >> >> <project> >> <parent> >> <groupId>org.apache.example<groupId> >> <artifactId>jee6eartest</artifactId> >> <version>1.0-SNAPSHOT<version> >> </parent> >> >> <artifactId>fooEar</artifactId> >> >> <dependancies> >> <dependency> >> <groupId>org.apache.example<groupId> >> <artifactId>fooejb</artifactId> >> <version>1.0-SNAPSHOT<version> >> <type>ejb</type >> </dependency> >> </dependancies> >> >> <build> >> <plugins> >> <plugin> >> <groupId>org.apache.maven.plugins</groupId> >> <artifactId>maven.ear.plugin</artifactId> >> <version>2.5</version> >> <configuration> >> <version>6</version> <!--- Java EE spec version???? --> >> <modules> >> <ejbModule> >> groupId>org.apache.example<groupId> >> <artifactId>fooejb</artifactId> >> </ejbModule> >> </modules> >> </configuration> >> <plugin> >> </plugins> >> </build> >> >> </project> >> >> When this is run, the ejb jar file is generate in its module, then >> Maven builds the ear module. >> >> The log shows >> [WARNING] JAR will be empty - no content marked for inclusion! >> [INFO] Building jar: >> C:\work\jee6eartest\fooEar\target\fooEar-1.0-SNAPSHOT.jar >> >> Does anyone have this working? >> >> --------------------------------------------------------------------- >> 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]
