Introduction

This plugin generates J2EE Enterprise Archive (EAR) file. It can also generate the deployment descriptor file (e.g. application.xml)

The full description of goals is available here.

Supported artifacts

The EAR plugin supports the following artifacts:

  • ejb
  • war
  • jar
  • ejb-client
  • rar
  • ejb3
  • par
  • sar
  • wsr

    If you need to map a custom artifact type to one of those types, use the 'customArtifactTypeMappings'.

    For instance, to map a custom 'my-rar' to the 'rar' standard artifact's type, add the following to the pom's configuration:

      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-ear-plugin</artifactId>
            <configuration>
              <artifactTypeMappings>
                <artifactTypeMapping type="my-rar" mapping="rar"/>
              </artifactTypeMappings>
            </configuration>
          </plugin>
        </plugins>
      </build>