war:inplace

Generates webapp in the source directory

Mojo Attributes :

  • Requires a Maven 2.0 project to execute.
  • Requires dependency resolution of artifacts in scope: runtime

Required Parameters

Name Type Description
cacheFile File The file containing the webapp structure cache.
warSourceDirectory File Single directory for extra files to include in the WAR.
webappDirectory File The directory where the webapp is built.
workDirectory File Directory to unpack dependent WARs into if needed

Optional Parameters

Name Type Description
archive MavenArchiveConfiguration The maven archive configuration to use.
archiveClasses boolean Whether a JAR file will be created for the classes in the webapp. Using this optional configuration parameter will make the generated classes to be archived into a jar file and the classes directory will then be excluded from the webapp. Default value is false.
containerConfigXML File The path to the context.xml file to use.
dependentWarExcludes String The comma separated list of tokens to exclude when doing a war overlay.
dependentWarIncludes String The comma separated list of tokens to include when doing a war overlay. Default is '**'
filters List Filters (property files) to include during the interpolation of the pom.xml.
outputFileNameMapping String The file name mapping to use to copy libraries and tlds. If no file mapping is set (default) the file is copied with its standard name.
overlays List The overlays to apply.
useCache boolean Whether the cache should be used to save the status of the webapp accross multiple runs. Default value is true.
warSourceExcludes String The comma separated list of tokens to exclude from the WAR.
warSourceIncludes String The comma separated list of tokens to include in the WAR. Default is '**'.
webResources Resource[] The list of webResources we want to transfer.
webXml File The path to the web.xml file to use.

Parameter Details

archive

The maven archive configuration to use.

  • Type : org.apache.maven.archiver.MavenArchiveConfiguration
  • Required : No

archiveClasses

Whether a JAR file will be created for the classes in the webapp. Using this optional configuration parameter will make the generated classes to be archived into a jar file and the classes directory will then be excluded from the webapp.

  • Type : boolean
  • Required : No
  • Expression : ${archiveClasses}
  • Default : false

cacheFile

The file containing the webapp structure cache.

  • Type : java.io.File
  • Since : 2.1
  • Required : Yes
  • Expression : ${project.build.directory}/war/work/webapp-cache.xml

containerConfigXML

The path to the context.xml file to use.

  • Type : java.io.File
  • Required : No
  • Expression : ${maven.war.containerConfigXML}

dependentWarExcludes

The comma separated list of tokens to exclude when doing a war overlay.

  • Type : java.lang.String
  • Required : No

dependentWarIncludes

The comma separated list of tokens to include when doing a war overlay. Default is '**'

  • Type : java.lang.String
  • Required : No

filters

Filters (property files) to include during the interpolation of the pom.xml.

  • Type : java.util.List
  • Required : No
  • Expression : ${project.build.filters}

outputFileNameMapping

The file name mapping to use to copy libraries and tlds. If no file mapping is set (default) the file is copied with its standard name.

  • Type : java.lang.String
  • Since : 2.0.3
  • Required : No

overlays

The overlays to apply.

  • Type : java.util.List
  • Since : 2.1
  • Required : No

useCache

Whether the cache should be used to save the status of the webapp accross multiple runs.

  • Type : boolean
  • Since : 2.1
  • Required : No
  • Expression : ${useCache}
  • Default : true

warSourceDirectory

Single directory for extra files to include in the WAR.

  • Type : java.io.File
  • Required : Yes
  • Expression : ${basedir}/src/main/webapp

warSourceExcludes

The comma separated list of tokens to exclude from the WAR.

  • Type : java.lang.String
  • Required : No

warSourceIncludes

The comma separated list of tokens to include in the WAR. Default is '**'.

  • Type : java.lang.String
  • Required : No

webResources

The list of webResources we want to transfer.

  • Type : org.apache.maven.model.Resource[]
  • Required : No

webXml

The path to the web.xml file to use.

  • Type : java.io.File
  • Required : No
  • Expression : ${maven.war.webxml}

webappDirectory

The directory where the webapp is built.

  • Type : java.io.File
  • Required : Yes
  • Expression : ${project.build.directory}/${project.build.finalName}

workDirectory

Directory to unpack dependent WARs into if needed

  • Type : java.io.File
  • Required : Yes
  • Expression : ${project.build.directory}/war/work