Prepare Source Code
Prepare Source Code
Dependent on | By | Documentation |
---|---|---|
Source control provisioning | IT Operations | Prepare Infrastructure |
Maven repository setup | Dev Ops | Setup Maven Repository |
Overview
This page describes how to prepare Elastic Path source code for use by your project. The diagram below shows the steps.
ep-aem-commerce and geometrixx-demo projects are only available with EP-Commerce-for-AMC-1.4.zip package
Setup local build environment
Unzip source release packages
EP source is delivered in multiple ZIP files. You should obtain one or more of the following release packages depending on your license and the environment you wish to create:
Release package | Contents |
---|---|
EP-Commerce-6.16.0.zip | Core Commerce, Cortex |
EP-Commerce-for-AMC-1.4.zip | EP Commerce for Adobe Marketing Cloud |
- Unzip the contents of the release packages into your project source folder. Warning: Windows File Path Limitation
Do not save your source projects to a directory that is greater than 20 characters in length. Windows file paths are limited to 260 characters. The longest file path in the source code is greater than 230 characters so be careful where you deploy your source files.
Add projects to source control
- Add the following projects to source control as separate repositories:
cmclient, commerce-engine,
devops, extensions, and the
ep-aem-commerce & geometrixx-demo projects
if applicable. Tip:
If you use GitHub or a similar Git hosting service, follow the instructions in Add Source to GitHub.
Tip:The commerce-data project is included in the release package for reference and doesn't need to be added to source control.
The cortex-ep-integration project is provided to make it easier to extend Cortex integration bundles. It can be added to source control and incorporated into your build process at a later time if needed.
- Create a development branch for each project. The branch name depends on your SCM and branch naming conventions.
Configure the project settings.xml
The extensions project you just added to source control has a maven/settings.xml the project teams will use.
- Replace the <mirror> <url> at the the top of the file with the <Project> EP Repository Group URL documented during Setup Maven Repository.
- Make any changes required for your project environment.
- Commit the changes to source control.
- Copy the settings.xml to your ${user.home}/.m2 directory.
Remove unlicensed modules
If you do not have a license for EP Commerce for AMC, you need to remove related dependencies from the extensions project source. Otherwise the build will fail when it attempts to get artifacts from Elastic Path Maven repository groups to which you don't have access.
The devops project: contains modules to remove EP Commerce for AMC references from the extensions project source:
Reversion projects for development
EP release packages contain projects with RELEASE versions. Prior to starting development, the projects must be reversioned to SNAPSHOT versions.
- Determine the version numbers to use for the development branch. For information on EP version number conventions and restrictions, see Construction Practices - Version Numbers.
- Ensure each project is checked out under the development branch.
- Follow the steps in Construction Practices - Update Version Numbers to reversion.