I have an ear project, and the pom contains the following lines - <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-ear-plugin</artifactId> <configuration> <modules> <javaModule> <groupId>commons-collections</groupId> <artifactId>commons-collections</artifactId> <includeInApplicationXml>true</includeInApplicationXml> <bundleDir>/</bundleDir> </javaModule> </modules> </configuration> </plugin>
I added this, hoping that the commons-collections jar file will appear in the final ear file. I get an error that reads: Artifact[commons-collections:commons-collections:jar] is not a dependency of the project. Can someone tell me how to resolve this? I tried adding a <dependency> for this, but it didnt work.