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

This version of Elastic Path Commerce is no longer supported or maintained. To upgrade to the latest version, contact your Elastic Path representative.

Set Up Maven Repository

Set Up Maven Repository

Note: Role: DevOps
Dependent on By Documentation
Maven repository manager server provisioning IT Operations Prepare Infrastructure

Overview

A Maven Repository Manager is an essential component for team development of Maven based projects. The Maven Project site explains why and provides a list of available Repository Managers.

Not all Maven artifacts that Elastic Path products depend on are provided in the release package. You will have to get those artifacts from Elastic Path's Maven Repository.

Tip: Nexus repository manager setup

If you plan to use the Nexus Repository Manager, a shell script is available to install and configure it. See Nexus Setup for detailed instructions.

Proxy external repositories

The following external Maven repositories are required and need to be proxied:

Warning:

The repository order is important and should match the table below. Using a different repository sequence can result in build errors.

Repository Provider Policy URL Credentials Required
Maven Central Maven2 Release http://central.maven.org/maven2/
Elastic Path Public Maven2 Release

https://repository.elasticpath.com/nexus/content/repositories/public/

Elastic Path Cortex Maven2 Release https://repository.elasticpath.com/nexus/content/repositories/cortex/
Elastic Path Commerce Engine Maven2 Release https://repository.elasticpath.com/nexus/content/repositories/commerce-engine/
Elastic Path Accelerators Maven2 Release https://repository.elasticpath.com/nexus/content/repositories/accelerators/
Java Net Repository For Maven Maven2 Release https://maven.java.net/content/repositories/releases/
Public JBoss Group Maven2 Release http://repository.jboss.org/nexus/content/groups/public-jboss
Sonatype Maven2 Release https://repository.sonatype.org/content/groups/forge
Wakaleo (for schemaspy) Maven2 Release http://www.wakaleo.com/maven/repos
Springsource Bundles Maven2 Release http://repository.springsource.com/maven/bundles/external
Springsource Zodiac Milestone Bundles Maven2 Release http://zodiac.springsource.com/maven/bundles/milestone
Springsource Milestone Maven2 Release https://maven.springframework.org/milestone/
Adobe Public Maven2 Release http://repo.adobe.com/nexus/content/groups/public
Adobe AEM Maven2 Release http://localhost:4502/maven/repository/ (see setup instructions below)
Note:

A username and password are required to access the Elastic Path repositories. For more information, see Download Prerequisites.

Depending on your Elastic Path license you may not have access to all repositories

Configure Adobe AEM as a Maven repository

You need to configure AEM as a Maven repository when:
  • AEM 's UberJar is broken
  • Your project's dependencies are unavailable in your local Nexus
To configure your AEM instance to act as a Maven repository:
  1. Install an AEM 6.1 author instance on your Maven repository server.
  2. Download and install the cq5-archiva-servlet-1.6.zip as documented in step 1 at https://helpx.adobe.com/experience-manager/kb/HowToUseCQ5AsMavenRepository.html.
  3. Configure a proxy for http://localhost:4502/maven/repository/. Remember to set the credentials to match your AEM instance.

Configure local repositories and groups

Once all external proxies have been configured, you will need to create local repositories and groups and build the repository hierarchy.

  1. Create a hosted repository (e.g. <project> EP Snapshots) with a "snapshot" policy.
  2. Create a hosted repository (e.g. <project> EP Releases) with a "release" policy.
  3. Create an External Proxy Repository Group and add all external proxies to it in the order defined in the Proxy external respositories section.
  4. Create a <project> EP Repository Group and add the hosted repositories and the External Proxy Repository Group to it.

Manual uploads

Some artifacts cannot be obtained from public Maven repositories because of licensing restrictions. These need to be manually uploaded to your Maven repository.

Artifact Source EP Dependency
MySQL JDBC driver

Download platform independent version 5.1.37 from http://downloads.mysql.com/archives/c-j/

<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>5.1.37</version>                       

User accounts

A user account with maven deployment privileges needs to be created for use by the Continuous Integration server to deploy build artifacts.

Deliverables

  • A fully functional Maven repository server