Announcement: You can find the guides for Commerce 7.5 and later on the new Elastic Path Documentation site. The Developer Center continues to support Commerce 6.13.0 through 7.4.1.Visit new site

Webapp Extension Project Structure

Webapp Extension Project Structure

A single Elastic Path Web Application extension consists of two parts: a JAR component and a WAR component. The JAR component contains the extended class files, while the WAR compnent contains the project configuration files. This separation of class files from project configuration files makes the web applications more robust and easier to maintain.

The JAR component has the following structure:

<artifact_id>
|--src  //Contains the package directory structure for the extension project. Your customized source code goes here.
|----main
|------java
|--------com
|----------java //Contains the java source extension files.
|------------<package_dirs>
|----------resources
|------------META-INF
|------------------conf
|--------------------<original-webapp-Name>-plugin.xml //Adds new bean definitions and overrides existing ones in the base application.
|--pom.xml

The WAR component has the following structure:

<artifact_id>
|--src
|----main
|------filtered-resources
|--------module.properties //Template file used to set Spring property values at build-time. For more info, see Build-time property configuration.
|----------resources
|------------META-INF
|------------------conf
|--------------------<original-webapp-Name>-plugin.xml //Adds new bean definitions and overrides existing ones in the base application.
|----------webapp
|------------WEB-INF
|------------------web.xml // Webapp's corresponding web.xml
|------------------weblogic //XML Files used for creating a WAR for deployment on Weblogic.
|--target
|--pom.xml