The maven-ear-plugin and the ear packaging type and why several goals get run

When building a Maven artifact of type ear, the ear packaging type is invoked.

The maven-ear-plugin replaces the maven-jar-plugin at this point, so it is as though you included it in your pom.xml.

The generate-application-xml goal binds by default to the generate-resources phase.

The ear goal binds by default to the package phase.

So at the end of the day by declaring a packaging type of ear, you cause two goals—not one—to be run.

Author: Laird Nelson

Devoted husband and father; working on Helidon at the intersection of Java, Jakarta EE, architecture, Kubernetes and microservices at Oracle; open source guy; Hammond B3 player and Bainbridge Islander.

%d bloggers like this: