My ear pom.xml contains this configuration:
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-ear-plugin</artifactId>
<configuration>
<modules>
<!-- Internal dependencies -->
<jarModule>
<groupId>org.drools.solver.examples</groupId>
<artifactId>examination-domain</artifactId>
<bundleFileName>examination-domain.jar</bundleFileName>
<includeInApplicationXml>true</includeInApplicationXml>
</jarModule>
<ejbModule>
<groupId>org.drools.solver.examples</groupId>
<artifactId>examination-business</artifactId>
<bundleFileName>examination-business.jar</bundleFileName>
</ejbModule>
<webModule>
<groupId>org.drools.solver.examples</groupId>
<artifactId>examination-web</artifactId>
<bundleFileName>examination-web.jar</bundleFileName>
<contextRoot>/messor-web</contextRoot>
</webModule>
<!-- Global libs -->
<jarModule>
<groupId>org.jboss.seam</groupId>
<artifactId>jboss-seam</artifactId>
<bundleFileName>jboss-seam.jar</bundleFileName>
<includeInApplicationXml>true</includeInApplicationXml>
</jarModule>
<jarModule>
<groupId>org.jboss.el</groupId>
<artifactId>jboss-el</artifactId>
<bundleFileName>jboss-el.jar</bundleFileName>
<includeInApplicationXml>true</includeInApplicationXml>
</jarModule>
</modules>
</configuration>
</plugin>
</plugins>
</build>
Everytime I use the maven synchronization feature, IntelliJ ignores the above configuration and overwrites working iml's with not working iml's.