Maven 공식 플러그인

PluginType*VersionRelease DateDescriptionSource RepositoryIssue Tracking
Core plugins


Plugins corresponding to default core phases (ie. clean, compile). They may have multiple goals as well.

cleanB3.1.02018-04-14Clean up after the build.Git / GitHubJira MCLEAN
compilerB3.8.12019-04-28Compiles Java sources.Git / GitHubJira MCOMPILER
deployB3.0.0-M12018-09-23Deploy the built artifact to the remote repository.Git / GitHubJira MDEPLOY
failsafeB3.0.0-M42019-11-17Run the JUnit integration tests in an isolated classloader.Git / GitHubJira SUREFIRE
installB3.0.0-M12018-09-23Install the built artifact into the local repository.Git / GitHubJira MINSTALL
resourcesB3.1.02018-04-23Copy the resources to the output directory for including in the JAR.Git / GitHubJira MRESOURCES
siteB3.9.02020-03-10Generate a site for the current project.Git / GitHubJira MSITE
surefireB3.0.0-M42019-11-17Run the JUnit unit tests in an isolated classloader.Git / GitHubJira SUREFIRE
verifierB1.12015-04-14Useful for integration tests - verifies the existence of certain conditions.Git / GitHubJira MVERIFIER
Packaging types/tools


These plugins relate to packaging respective artifact types.

earB3.0.22019-11-11Generate an EAR from the current project.Git / GitHubJira MEAR
ejbB3.0.12018-05-03Build an EJB (and optional client) from the current project.Git / GitHubJira MEJB
jarB3.2.02019-11-03Build a JAR from the current project.Git / GitHubJira MJAR
rarB2.42014-09-08Build a RAR from the current project.Git / GitHubJira MRAR
warB3.2.32019-05-23Build a WAR from the current project.Git / GitHubJira MWAR
app-client/acrB3.1.02018-06-19Build a JavaEE application client from the current project.Git / GitHubJira MACR
shadeB3.2.32020-04-13Build an Uber-JAR from the current project, including dependencies.Git / GitHubJira MSHADE
sourceB3.2.12019-12-21Build a source-JAR from the current project.Git / GitHubJira MSOURCES
jlinkB3.0.0-alpha-12017-09-09Build Java Run Time Image.Git / GitHubJira MJLINK
jmodB3.0.0-alpha-12017-09-17Build Java JMod files.Git / GitHubJira MJMOD
Reporting plugins


Plugins which generate reports, are configured as reports in the POM and run under the site generation lifecycle.

changelogR2.32014-06-24Generate a list of recent changes from your SCM.Git / GitHubJira MCHANGELOG
changesB+R2.12.12016-11-01Generate a report from an issue tracker or a change document.Git / GitHubJira MCHANGES
checkstyleB+R3.1.12020-02-08Generate a Checkstyle report.Git / GitHubJira MCHECKSTYLE
doapB1.22015-03-17Generate a Description of a Project (DOAP) file from a POM.Git / GitHubJira MDOAP
docckB1.12015-04-03Documentation checker plugin.Git / GitHubJira MDOCCK
javadocB+R3.2.02020-03-16Generate Javadoc for the project.Git / GitHubJira MJAVADOC
jdepsB3.1.22019-06-12Run JDK's JDeps tool on the project.Git / GitHubJira MJDEPS
jxrR3.0.02018-09-25Generate a source cross reference.Git / GitHubJira JXR
linkcheckR1.22014-10-08Generate a Linkcheck report of your project's documentation.Git / GitHubJira MLINKCHECK
pmdB+R3.13.02020-01-25Generate a PMD report.Git / GitHubJira MPMD
project-info-reportsR3.0.02018-06-23Generate standard project reports.Git / GitHubJira MPIR
surefire-reportR3.0.0-M42019-11-17Generate a report based on the results of unit tests.Git / GitHubJira SUREFIRE
Tools


These are miscellaneous tools available through Maven by default.

antrunB3.0.02020-04-15Run a set of ant tasks from a phase of the build.Git / GitHubJira MANTRUN
archetypeB3.1.22019-08-22Generate a skeleton project structure from an archetype.Git / GitHubJira ARCHETYPE
assemblyB3.2.02019-11-03Build an assembly (distribution) of sources and/or binaries.Git / GitHubJira MASSEMBLY
dependencyB+R3.1.22020-03-07Dependency manipulation (copy, unpack) and analysis.Git / GitHubJira MDEP
enforcerB3.0.0-M32019-11-23Environmental constraint checking (Maven Version, JDK etc), User Custom Rule Execution.Git / GitHubJira MENFORCER
gpgB1.62015-01-19Create signatures for the artifacts and poms.Git / GitHubJira MGPG
helpB3.2.02019-04-16Get information about the working environment for the project.Git / GitHubJira MPH
invokerB+R3.2.12019-09-13Run a set of Maven projects and verify the output.Git / GitHubJira MINVOKER
jarsignerB3.0.02018-11-06Signs or verifies project artifacts.Git / GitHubJira MJARSIGNER
jdeprscanB3.0.0-alpha-12017-11-15Run JDK's JDeprScan tool on the project.Git / GitHubJira MJDEPRSCAN
patchB1.22015-03-09Use the gnu patch tool to apply patch files to source code.Git / GitHubJira MPATCH
pdfB1.42017-12-28Generate a PDF version of your project's documentation.Git / GitHubJira MPDF
pluginB+R3.6.02018-11-01Create a Maven plugin descriptor for any mojos found in the source tree, to include in the JAR.Git / GitHubJira MPLUGIN
releaseB3.0.0-M12019-12-08Release the current project - updating the POM and tagging in the SCM.Git / GitHubJira MRELEASE
remote-resourcesB1.7.02020-01-21Copy remote resources to the output directory for inclusion in the artifact.Git / GitHubJira MRRESOURCES
scmB1.11.22019-03-21Execute SCM commands for the current project.Git / GitHubJira SCM
scm-publishB3.0.02018-01-29Publish your Maven website to a scm location.Git / GitHubJira MSCMPUB
stageB1.02015-03-03Assists with release staging and promotion.Git / GitHubJira MSTAGE
toolchainsB3.0.02019-06-16Allows to share configuration across plugins.Git / GitHubJira MTOOLCHAINS

유용한 플러그인

플러그인Group IDArtifact ID사용 용도
Addjars Plugincom.googlecode.addjars-maven-pluginaddjars-maven-plugin
  • 외부의 JAR 파일을 WAR, JAR 파일 내부에 포함시키고자 하는 경우
    • Spring Boot의 경우 Maven Repo에 등록되어 있는 Artifact인 경우에만 추가가 가능하나 이 플러그인을 사용하면 JAR#lib 디렉토리에 추가할 수 있음
Shade Pluginorg.apache.maven.pluginsmaven-shade-plugin
  • JAR 파일 내에 .class 파일들의 패키지명을 변경하고자 하는 경우
    • Hadoop의 JAR 파일에는 Servlet API 등이 이미 포함되어 있어서 웹 애플리케이션에서 Hadoop JAR 파일을 이용하는 경우 Servlet API이 포함되어 있으므로 웹 애플리케이션 실행시 에러가 발생함
    • 이 경우 Hadoop JAR 파일에 있는 Servlet API의 패키지를 임의의 패키지로 명으로 변경하여 출동을 회피할 수 있음